Good Evening Statalist,
I'm trying to take the values of the following variables, and stack them into one column.
I actually have over two-hundred similar variables. I would like to stack them into one column. I tried to use the
command, and tried to follow some of the posts here, but I keep getting invalid syntax. I'm not sure what I'm doing wrong. I want them into one long column, because the data is ordered by county and years. (For example, the first column are values for Country A between 2000-2016). Thank you in advance.
I'm trying to take the values of the following variables, and stack them into one column.
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input float(v1 v2 v3 v4 v5 v6 v7 v8 v9 v10) 98583.65 2689.404 39363.97 956.384 198349.94 19176.32 41658.11 14610875 2956.389 31561.92 102967.47 1425.272 66995.945 1043.32 173146.16 12588.352 20920.59 15258652 397.702 12350.628 83608.82 787.546 23464.066 972.375 166769.4 16800.342 30197.59 16721873 421.001 41698.17 106049.66 682.952 15559.797 527.214 191980.97 12614.84 14221.04 18962966 1292.407 36579.727 113240.53 1637.298 25359.62 232.069 273081.7 12200.224 74230.52 22733624 591.017 18066.707 104162.4 572.742 88162.01 667.438 307729.8 72783.21 179674.44 26220594 484.496 34124.22 155877.78 633.475 16615.023 1107.778 377619 27026.953 253609.83 28031248 830.957 27532.68 113431.47 5120.94 24307.29 837.954 376820.75 26385.254 188838.2 27193410 44.141 43695.1 163516.67 32832.684 140704.28 463.761 526008.06 27973.33 219713.38 32072884 2121.059 11183.41 108074.3 474.194 13613.933 219.972 522529.9 26076.73 132737.53 21017804 403.216 6264.399 130121.13 301.185 23073.35 406.481 694166.9 26864.92 170456.1 25009190 1477.915 19216.52 199976.23 2018.589 60304.96 543.454 915072.3 51573.54 294171.88 32838644 6083.098 6703.542 161832.1 2673.58 83778.19 568.747 1682149.4 51579.9 221039.06 32123374 19452.854 13451.702 127129.43 3128.498 60814.6 538.582 1251391 57733.7 277714.44 27630990 17739.893 6361.995 103531.1 5534.069 37125.605 306.482 1943178 86158.93 323786.1 31607114 14304.836 11046.25 81461.02 5111.324 109290.13 3621.451 1014381 81000.57 220334.34 28517866 16154.084 16795.736 58080.41 7272.705 25207.12 4272.858 983769.9 78399.47 444441.1 27057612 12222.92 31385.52 end
Code:
reshape long
Comment