I am in need of two different tuples lists, so I would like to store one set as a local and call the other in a different loop.
Below is the command i am trying to store. I do not think it is storing the list because when I call the new local list in the second loop it does not recognize the local macro sp`i'. I am trying the following command to store the tuples (tuple1, tuple2, tuple3,...) to sp`i' (eg. sp1, sp2, sp3...) .
tuples x y z w
forval i =1/15 {
local sp`i' `tuple`i''
}
As a bonus question is there a command to count the number of tuples created so I can make the indexing more flexible? So instead of 15 it would be max(tuples), or something similar.
Thanks!
[Tuples is a really cool command. Thanks whoever created it!!!]
Related Posts with Local macro list and tuples
PPML and fixed effects commandsGood evening, guys. I'm currently working on a gravity model with PPML estimator. Here is the thread…
do we have simpler syntax to realize this goal? Code: if lnEmployee1Y ~=. & lnCash1Y~=. & lnTtlAsset1Y~=. & stdRevenue1Y~=. & stdNe…
reshape errorHi, I am trying to reshape from wide to long, but it keeps saying that "variable id does not uniquel…
Exact matching on Propensity Score MatchingDear Stata Forum, I’m trying to perform a Propensity Score Matching with exact matching but found m…
ttesti: using se as input instead of sdHi everyone, I am trying to calculate the independent t-test using ttesti which requires mean, sd, a…
Subscribe to:
Post Comments (Atom)
0 Response to Local macro list and tuples
Post a Comment