Dear all,
I am new with stata and currently trying to figure out how to make the following loop work:
forval i=1/2 {
import excel using U:\Stata\Test_`i', firstrow
nl (CE = ({b0=0.5}*(y^{b1=0.8} - x^{b1=0.8})+x^{b1=0.8})^(1/{b1=0.8}))
gen Alpha_`i'=_b[/b1]
}
I get following error Code: no; data in memory would be lost
I think the key is to somehow extract Alpha as a hard value.
Thank you in Advance.
Stefan
Related Posts with Saving variables in foor loop
How to reset a loop with a continues set of codes?Hi everyone, I hope you are doing well. I'm posting here because I have a doubt regarding a loop I'…
How to use the results of LCA(Latent Class Analysis) in the next step of regression analysis?Hello! I used gsem to perform an LCA analysis and separated the categories. How can I use this cate…
Inclusion of both Age and Time Indicators in Panel Data AnalysisDear Colleagues, I am analyzing a panel data that collects information on children every two years …
Using value labels in graphs through loopsHi all, I am trying to create a graph of weekly_count_visittype (Y axis) and week_num (X axis) separ…
'SWEXP': piecewise exponential distribution functionI thank Kit for making a command swexp available on SSC. This command calculates quantities from a …
Subscribe to:
Post Comments (Atom)
0 Response to Saving variables in foor loop
Post a Comment