楼主: 不高兴的羊
705 0

stata 低频数据转高频(季度转日度)如何实现? [推广有奖]

  • 2关注
  • 0粉丝

VIP1

硕士生

48%

还不是VIP/贵宾

-

威望
0
论坛币
1958 个
通用积分
43.0582
学术水平
0 点
热心指数
0 点
信用等级
0 点
经验
2479 点
帖子
103
精华
0
在线时间
115 小时
注册时间
2017-3-10
最后登录
2021-12-14

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

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

经管之家联合CDA

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

感谢您参与论坛问题回答

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

+2 论坛币
我下载的个股财务杠杆和账面市值比都是季度的数据,想转为日度数据,请问如何实现呢?

----------------------- copy starting from the next line -----------------------
  1. * Example generated by -dataex-. To install: ssc install dataex
  2. clear
  3. input str6 Stkcd float(Date LEV BM)
  4. "000002" 21457 1.146224  .964731
  5. "000002" 21549  1.08892  .982434
  6. "000002" 21639 1.313664  .937771
  7. "000002" 21730  1.11641  .950663
  8. "000002" 21822 1.115368  .971616
  9. "000002" 21914 1.074941  .948919
  10. "000002" 22005 1.471233  .991006
  11. "000002" 22096 1.125107  .993164
  12. "000002" 22188 1.114664  .987544
  13. "000002" 22280 1.064576  1.00886
  14. "000002" 22370  1.38672  1.00363
  15. "000063" 16982 1.111947  .566728
  16. "000063" 17074  1.19291  .538784
  17. "000063" 17166 1.224021  .496556
  18. "000063" 17256 2.346933  .482847
  19. "000063" 17347 1.311644  .469436
  20. "000063" 17439 1.294167  .460933
  21. "000063" 17531 1.286138  .448222
  22. "000063" 17622 2.074913  .488662
  23. "000063" 17713 1.462651   .49645
  24. "000063" 17805 1.703219  .645302
  25. "000063" 17897 1.578223   .70431
  26. "000063" 17987 3.381124  .628543
  27. "000063" 18078 1.303297   .65047
  28. "000063" 18170  1.29662  .527079
  29. "000063" 18262 1.236026  .515536
  30. "000063" 18352 2.225113  .534488
  31. "000063" 18443 1.531737  .690516
  32. "000063" 18535 1.306154  .612668
  33. "000063" 18627 1.274867   .61223
  34. "000063" 18717 1.583779  .596463
  35. "000063" 18808 1.346089  .631535
  36. "000063" 18900 1.924224  .715838
  37. "000063" 18992 1.894193  .767896
  38. "000063" 19083 1.363138  .774968
  39. "000063" 19174 2.267575  .833798
  40. "000063" 19358        .  .907882
  41. "000063" 19448 3.165516  .865495
  42. "000063" 19539 2.943369  .829494
  43. "000063" 19631 2.826073  .746139
  44. "000063" 19723 2.346014  .824497
  45. "000063" 19813 1.268961  .843532
  46. "000063" 19904 1.308987  .833992
  47. "000063" 19996 1.534647  .793991
  48. "000063" 20088 1.593795  .747968
  49. "000063" 20178 1.720235  .735033
  50. "000063" 20269 1.470084  .712331
  51. "000063" 20361 1.335871  .804005
  52. "000063" 20453  1.33247  .780592
  53. "000063" 20544 1.111316  .875685
  54. "000063" 20635  .964895  .892557
  55. "000063" 20727 1.033625  .893447
  56. "000063" 20819        .  .845614
  57. "000063" 20909  .990943  .828324
  58. "000063" 21000 1.087959  .719885
  59. "000063" 21092 1.112349  .664977
  60. "000063" 21184 1.155305  .573492
  61. "000063" 21365        .  .852277
  62. "000063" 21549        .  .724555
  63. "000063" 21639 1.560336  .610006
  64. "000063" 21730 1.296231  .578441
  65. "000063" 21822 1.092868  .602768
  66. "000063" 21914 1.134878   .55842
  67. "000063" 22005 1.870895  .487269
  68. "000063" 22096 1.222752  .540112
  69. "000063" 22188 1.173519  .604899
  70. "000063" 22280 1.083042  .579913
  71. "000063" 22370 1.149438  .641938
  72. "000066" 16982  .972822  .650691
  73. "000066" 17074  .968294  .711033
  74. "000066" 17166  .938979  .727992
  75. "000066" 17256  .965674  .527378
  76. "000066" 17347  1.01471  .535085
  77. "000066" 17439 1.094212  .434683
  78. "000066" 17531 1.212695  .461073
  79. "000066" 17622 5.104902  .574584
  80. "000066" 17713 1.671842  .835362
  81. "000066" 17805 2.661818  .951487
  82. "000066" 17897 5.615477  .797973
  83. "000066" 17987 1.468755  .633396
  84. "000066" 18078 1.196008  .509399
  85. "000066" 18170 1.173138  .547582
  86. "000066" 18262 1.159464  .977657
  87. "000066" 18352 1.258292  .986353
  88. "000066" 18443 1.414269  1.03674
  89. "000066" 18535  .966281  .951801
  90. "000066" 18627  .986344  .941281
  91. "000066" 18717  .484187  .967756
  92. "000066" 18808   .33182 1.043311
  93. "000066" 18900   .94867 1.091419
  94. "000066" 18992 1.109036 1.124992
  95. "000066" 19083  .225103 1.154963
  96. "000066" 19174  3.43508 1.157313
  97. "000066" 19266 1.803335 1.145658
  98. "000066" 19358 2.582588 1.174611
  99. "000066" 19448        . 1.180134
  100. "000066" 19539        . 1.170781
  101. "000066" 19631        . 1.090976
  102. "000066" 19723        . 1.103269
  103. "000066" 19904        . 1.064006
  104. end
  105. format %tdCCYY-NN-DD Date
复制代码

------------------ copy up to and including the previous line ------------------



二维码

扫码加我 拉你入群

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

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

关键词:Stata 如何实现 tata generated including Stata教程 STATA数据 stata学习 Stata;Data stata编程

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

本版微信群
加JingGuanBbs
拉您进交流群

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

GMT+8, 2024-11-5 22:52