I am trying to store results across a large loop. I have previously done as follows but am limited to the matrix size (11000).
matrix z=J[1,6,.]
matrix Catch=J[`n',1]
forval i =1/`n' {
quietly reg y x`i'
quietly estat ic
matrix z=r(S)
matrix Catch(`i',1)=z[1,5]
}
Where `n' is a number significantly greater than >11000.
Is there a way to store these values elsewhere or output them quickly? I know I can use the "putexcel" command but it is slow having to call the command in each loop. Are there other options?
Related Posts with Storing results with a large loop (>11000)
Indicate loss of observations by variableDear Statalist Community, I am looking for a command that tells me how many observations are lost w…
How to create a graph like this in STATA?I am conducting an event study where I want to graph out cumulative abnormal returns surrounding the…
Creating Portfolios Sorted On Two VariablesHi Everyone, I have currency data that I want to initially sort on NFA(Net Foreign Assets) into two…
Keep/drop command affects different data than replacethe sample produced by this code replace region =. if region==-1 drop if region==. sum if region ==…
quesiton about Stata programDear all, I want to write a program to transform World Development Indicator(WDI) to panel data.Also…
Subscribe to:
Post Comments (Atom)
0 Response to Storing results with a large loop (>11000)
Post a Comment