我将锐思数据库下载下来的excel数据直接导入stata14,日期呈现30Jan2010的形式,为数值型数据,不知道如何分离出年份与月份?请各位前辈和老师指教~
. dataex Stkcd Accper 机构投资者持有A股比例_TotInsHoldperA in 1/20
----------------------- copy starting from the next line -----------------------
[CODE]
* Example generated by -dataex-. To install: ssc install dataex
clear
input str6 Stkcd int Accper double 机构投资者持有A股比例_TotInsHoldperA
"000002" 15156 .099051
"000002" 15340 .131773
"000002" 15521 .135864
"000002" 15613 .115236
"000002" 15705 .145403
"000002" 15886 .070986
"000002" 16070 .167411
"000002" 16252 .267346
"000002" 16344 .237202
"000002" 16436 .396038
"000002" 16526 .246494
"000002" 16617 .29196
"000002" 16709 .133805
"000002" 16801 .375607
"000002" 16891 .336517
"000002" 16982 .209282
"000002" 17074 .259574
"000002" 17166 .375594
"000002" 17256 .312577
"000002" 17347 .412371
end
format %td Accper
[/CODE]
------------------ copy up to and including the previous line ------------------
Listed 20 out of 60000 observations


雷达卡




京公网安备 11010802022788号







