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
Requeasting for the exact command to simpson diversifcation index in stataHello, Dear all, I am new for the stata software. Would you please show me the appropriate command t…
dyndoc and css formatingHi all. I run the -dyndoc- command in stata15. I include in my code header and css codes. When I s…
Issue With Quarterly Data FormatHello Stata community, I am having an issue when trying to create a simple "difference" variable, be…
behavior of saved outputDear lister I am using Stata17 I want to save the output from 2 table commands in 2 matrixes. Afte…
Do Not Rank If ConditionHello, In the sample attached I have ranked var: tfr_lr in var: rank_tfr_lr I would like var: tfr_l…
Subscribe to:
Post Comments (Atom)
0 Response to Local macro list and tuples
Post a Comment