Hi statalisters,
I want to use global macro's to refer to folder names, but ran into some unexpected behaviour when using them before the underscore "_" symbol.
Stata seems to ignore the macro that goes before the underscore.
*For example when i do this:
global year "2019"
global month "10"
di "$year_$month"
The console prints: "10" and ignores my call for year.
I want to get to "2019_10".
Could someone explain to me why the first macro gets ignored, and how i could solve it?
Thanks in advance!
Related Posts with Probem with using global macro in a string before an underscore
Industry and Country effect cross sectional regressionHello Statalist Forum, I am looking at the industry and country effect in 16 countries and 10 indus…
Interpolate (extrapolate) values (mipolate)Hi Everyone, As my data set has some missing values, I have used the "mipolate" command found in st…
Non-linear constraint in a SURE estimationDear Statalist contributors, I am trying to estimate a system of seemingly unrelated labor supplies…
Construct the standard error for the SCAR (event study)Dear Stata community, I'm trying to replicate the empirical strategy of the paper from Aybar and Ay…
Pesaran CSD Test Keeps Giving Errors!Hi everyone, I use Stata13 and I have a panel data of 38 countries across 6 years. I tried performin…
Subscribe to:
Post Comments (Atom)
0 Response to Probem with using global macro in a string before an underscore
Post a Comment