Hello,
I have data set and I want to do a simulation for 1,000,000 times. For each iteration, I randomly pick one observation out of that data set and save that single observation (with many variables) in new data set for later use. However, if I use "save" command in Stata format, that does not have "modify" option, which add other row to save the new observation that I pick. The only option is replace, which I do not want to because I want to keep all 1,000,000 observations from 1,000,000 iterations that I run.
Do you have any suggestion on how to save in a Stata format with "modify" option? or any command that can solve this problem.
P/S: I tried to do "putexcel", however, I have to do more iterations at one time, and it may exceed the number of rows in excel.
Thank you!
I have data set and I want to do a simulation for 1,000,000 times. For each iteration, I randomly pick one observation out of that data set and save that single observation (with many variables) in new data set for later use. However, if I use "save" command in Stata format, that does not have "modify" option, which add other row to save the new observation that I pick. The only option is replace, which I do not want to because I want to keep all 1,000,000 observations from 1,000,000 iterations that I run.
Do you have any suggestion on how to save in a Stata format with "modify" option? or any command that can solve this problem.
P/S: I tried to do "putexcel", however, I have to do more iterations at one time, and it may exceed the number of rows in excel.
Thank you!
Comment