楼主: davalic
2977 5

[其他] 讨论:stata 如何读取超过255个字符的字符型变量 [推广有奖]

  • 2关注
  • 1粉丝

博士生

87%

还不是VIP/贵宾

-

威望
0
论坛币
1050 个
通用积分
325.0629
学术水平
12 点
热心指数
16 点
信用等级
8 点
经验
490 点
帖子
146
精华
0
在线时间
547 小时
注册时间
2005-7-3
最后登录
2023-12-8

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
哪位高手知道stata怎么处理长度超过255个字符的字符型变量

数据结果如下

id          str1

1           sdfffddsfdsdsssfdfghhgh....fdfdf (一共有1000多个字母)
2           dsffdfdfddffsdfsdsdfsfdfdfg.....


stata只能读取前255个。不知有什么高招没有
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:Stata 字符型变量 tata 字符型 dsfds 如何 高招 字母

回帖推荐

arlionn 发表于6楼  查看完整内容

You can dowload the user written program -egenmore-, which provides several functions that fit your need. e.g. incss(strvarlist) , substr(substring) [ insensitive ] indicates occurrences of substring within any of the variables in a list of string variables by 1 and other observations by 0. insensitive makes comparison case-insensitive. (Stata 6 required; an alterna ...

eblog 发表于2楼  查看完整内容

呵呵,建议你用word help limits 可查看Stata受限清单

本帖被以下文库推荐

沙发
eblog 发表于 2010-2-8 18:41:23 |只看作者 |坛友微信交流群
呵呵,建议你用word
help limits 可查看Stata受限清单

使用道具

藤椅
davalic 发表于 2010-2-8 20:08:41 |只看作者 |坛友微信交流群
要用stata分析那些系列的分布特征

使用道具

板凳
eblog 发表于 2010-2-8 20:48:24 |只看作者 |坛友微信交流群
变量的分布也取值的长度也没什么关系啊

使用道具

报纸
davalic 发表于 2010-2-9 08:08:59 |只看作者 |坛友微信交流群
要算出不同的字母在序列中出现的频率,如何处理

使用道具

地板
arlionn 在职认证  发表于 2010-2-9 08:40:02 |只看作者 |坛友微信交流群
You can dowload the user written program -egenmore-, which provides several functions that fit your need.
e.g.

incss(strvarlist) , substr(substring) [ insensitive ] indicates occurrences of
        substring within any of the variables in a list of string variables by 1 and
        other observations by 0. insensitive makes comparison case-insensitive.
        (Stata 6 required; an alternative is now just to use foreach.)

noccur(strvar) , string(substr) creates a variable containing the number of
        occurrences of the string substr in string variable strvar.  Note that
        occurrences must be disjoint (non-overlapping): thus there are two
        occurrences of "aa" within "aaaaa". (Stata 7 required.)

    nss(strvar) , find(substr) [ insensitive ] returns the number of occurrences of
        substr within the string variable strvar.  insensitive makes counting
        case-insensitive. (Stata 6 required.)
已有 1 人评分论坛币 收起 理由
dxystata + 5 好的意见建议

总评分: 论坛币 + 5   查看全部评分

使用道具

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注jltj
拉您入交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-4-28 00:58