I want to use _N in place of the total count of observations in a loop like this:
forvalues i = 1(1)_N {
}
instead of directly putting the number. But I'm getting an "Invalid syntax" error. Can anyone help me with this or suggest any alternative?
Related Posts with Error while using _N in forvalues loop
ranksum test porder optionHi all, Good morning! I have done wilcoxin ranksum test with porder in STATA the variable we are te…
DiD with kernel PSMDear Statalist users, I am trying to combine a difference-in-difference design with kernel propens…
Interpreting results from an IVProbit RegressionHello...i need some serious help. I am running a regression (its huge by the way, not sure if you al…
how to check whether a variable varies over time for each individual in a panel dataDear Statalist, I have a balanced panel data with life satisfaction for each individual over three …
Add common term to a list of different variable labelsHi All, I'm trying to add a common term to the existing variable labels of a dataset, "LPI: ", so t…
Subscribe to:
Post Comments (Atom)
0 Response to Error while using _N in forvalues loop
Post a Comment