Stata store variables in local. 5497823654 local ProbF %9.

Stata store variables in local Your use of local macros is a bit off. Though each has a different first line, Is this the structure of your real dataset? If so, the numerical part of a variable name starts at the second position. Nov 20, 2024 · store the length of local cmake in local cmake_len calculate unique groups of car_make and store in local cmake pull out the first word from the make variable see also capture and scalar _rc Stata has three options for repeating commands over lists or values: foreach, forvalues, and while. 1 Storing Results. I hope there are good solutions. A local name is usually enwrapped between two backticks. Assume that you have a data variable called alpha and a scalar called beta:. Nov 25, 2014 · Daniel's post mentioning findname and mine were sent at about the same time. But I don't know how to reference the whole variables. Even that is just a speculation on my part as I do not use and do not know anything about -ivreg2-. What I would like to do is the following: Loop through the variables. Changing the composition of the group would allow easy re-estimation without having to change 10 equations. webuse lifeexp, clear (Life expectancy, 1998) May 20, 2016 · Dear Nick, I didn't want to store a matrix in a local macro, but only one element of the matrix (i. And from what I understand, global does the same Radu Ban wrote > thanks to those who replied to my previos queries. Of note, var x1-x1129 have completely different names, such as aa_a_15_30018338, and I don't want to change var names if possible. On Wed, Oct 24, 2012 at 10:46 AM, Charalambos Karagiannakis < [email protected] > wrote: > The loop below labels the new variables using the name of the > original variables (see Re: st: store variable names in local macro. From: Pablo Bonilla <[email protected]> Re: st: create local with specific value of a variable. If the latter, once you store the variable names in a macro (with ds, for example) you can then access the variable label with the extended macro function variable label. I want to write a loop that renames all of these variables "grocery_eggs", "grocery_butter", etc Sep 19, 2020 · I have a dataset imported into STATA. Perhaps just putting its value into // a list would work for you. Here we will cover two popular applications of locals. For example, I have a variable v012a but its value labels // label variables cap la dir local labels `"`r(names)'"' foreach varlab of local labels {preserve uselabel, clear var local newvarlist `"`r(`varlab')'"' st: store means as a new variable. So my issue is *Store higher level volume variable set local volume `volume_1' `volume_2' `volume_3'-`volume_20' local other_vars any_varlist Nov 15, 2020 · What you have is on the right track. Max, You can save value label in a macro using the macro extended functions. For instance, a local macro i of the variable "overall" should display the following: 1"Diesel:49. From: Maarten buis <[email protected]> Prev by Date: Fwd: Re: st: RE: store variable names in local macro; Next by Date: Re: st: RE: store variable names in local macro; Previous by thread: Re: st: store variable names in local macro; Next by thread: st: RE: store variable names in local macro; Index Jan 31, 2020 · Locals containing a list of variables can be very useful when using Stata. Please see my example below. 1 "First variable label" 2 "Second variable label" to be used in a figure for defining the legend. Mar 29, 2016 · Andrew, I'm not sure if you mean you want to store only those variables with value labels (Nick's suggestion in #2 addresses this), OR, you want to store a list of variables along with their value labels. Is this possible? Does STATA store the filename in memory somewhere? The filename is in the following format: identifier_date_form. What this code snippet does is scan through a locally-defined range of variables, and constructs an aggregate degree day measure relative to an adjustable lower bound (y). Mar 27, 2020 · A local is created locally, that is, within the current session. g. labvalpool (in turn Daniel's program from SSC, as you are Mar 10, 2020 · In the loop command I would like to store each estimate of 1129 regressions for vars x1-x1129 as E2-E1130, but I am not sure how to insert "est store" within the command. 1 that could store all estimates (not only the last one) for the mean from the 'sum' command when I use the prefix by/bysort: if you really want to store them as variables, you can do this: Code: You would probably be better off storing them as scalars or local macros Dec 9, 2017 · If you went to the grocery store today, would you 1) buy eggs, yes/no 2) buy butter, yes/no 3) buy vegetables, yes/no Currently, variable representing question 1 is v_1, var representing question 2 is v_2, etc. The first use of local macros is to store the results of our code. Apr 7, 2015 · Dear Statalist, I am running Stata 12. In all my courses that use Stata, I never really understood the difference between a local and global macro. local ProbF = 1. however there's one more thing i need to do. Nick [email protected] Christian Rauh In the hope not to have overlooked something obvious in the help files or in the statlist archives, here's my problem: I wonder whether it is possible to store certain variable values that come as an output of a list command into a local macro. > > > > So, unless you are using an ancient Stata, the previous versions are > > of > > no current interest. May 22, 2022 · I'm using Stata 16. This local can be created by means of the ds command. I don't know why so many people call it statlist. So, I have a list of variables with a similar structure: y_a_x, y_b_x, y_c_x, etc. com Remarks are presented under the following headings: Treatment of adornment Treatment of duplicate elements in lists Feb 9, 2022 · Suppose you want to store . 66%" . ) This work recommends that practitioners store each row of a string matrix in a separate local, indexed by a sequential identifier which allows users to manage and organize them in memory efficiently. Since this is a You can store any coefficient from your last estimated model in a local macro and use it later in the same program. )' } di "`numnames'" If this is what you want, fine. here the [1,2]), which I do (see my code local c1=m[1,2]), but only after copying the matrix named r(C) into the matrix named m (or rather, after creating a new matrix m equal to r(C). While importing, variable names get changed to lowercase but their value label names stay as is. Instead it is a "local macro", often abreviated as a "local". Jul 2, 2014 · Forums for Discussing Stata; General; You are not logged in. Something like: Nov 16, 2022 · After identifying the variables, we can create a local list containing these variables. I have a large number of variables starting with either with urb7, urb8 or urb9. April 2010 22:15 To: [email protected] Subject: st: Placing a string variable in a local/global Dear Statalisters, I am assigning the names of certain observations from variable X to a local/global with the command: local n = X[_N]. We recommend that practitioners store each row of a string matrix in a separate local. local all variables 02 Jul 2014, 20:50. g Yes/No, Male/Female, Increase/Decrease) in a local to Jan 31, 2020 · Locals containing a list of variables can be very useful when using Stata. (By the way, -copydesc- morphed into -clonevar-, people still using Stata 6 or 7. Feb 25, 2025 · 2estimates—Saveandmanipulateestimationresults Command,continued Reference,continued Tablesandstatistics estimatestable[namelist] [R]estimatestable etable [R]etable Dec 13, 2017 · which followed a parmest dump of model estimates. 3 3. . The local is intended as an input to a program. May 29, 2024 · Recognize the difference between data set variables and Stata variables. I didn't realize you have to run the whole block (including macro assignment, cleaning, and reg, for instance) in one shot. Therefore I want to write a command that takes a variable ID, 1) preserves the current sort order of the data, and 2) creates a new variable LevelsOfID which contains the levels of ID in increasing order, with the first level in the first observation, the Apr 8, 2015 · // Data set clear set obs 100 local i = 1 while `i' <= 5 { gen messy_var_`i' = runiform() label variable messy_var_`i' /// `"Some nonsense and figure that I need `=floor((2012-2001+1)*runiform() + 2001)'"' local i = `i' + 1 } la var messy_var_2 "Some nonsense and figure that I need 2005. My strategy is to create the local via a loop and adding each set of explanatory variables in turn (controls_1 - controls_3). -getmata- does this for you, which is why I like it. From: Wencke <[email protected]> Prev by Date: st: store means as a new variable; Next by Date: Re: st: store means as a new variable; Previous by thread: st: store means as a new variable; Next by thread: Re: st: store means as a new variable; Index(es): Date; Thread Dec 10, 2014 · where macro tofind contained an element to be found in list (macro) variables, you might code local i : list posof ‘"‘tofind’"’ in variables element must be enclosed in simple or compound quotes. Thanks for reading. However, I would like to automize this. Those variables have to fulfill two conditions: 1) some observation has to take on value "-8" and 2) the corresponding value label for this observation has to say - for example - "Stata". For example, after generating 5 lags for the variable "change" named L1 - L5: That was it! Thanks, Phil. " (p. This tip focuses on a common misunderstanding of how local macros work. If, however, there is more than one alpha or more than one beta, Stata always selects the data-variable interpretation in preference to the scalar. With local projections, you can estimate impulse–response functions directly using multistep regressions. > I made some regressions and want to save the constants of the different regressions in the form of a new variable so that I can make further calculations with the Nov 16, 2022 · With impulse–response functions, you can find out how a shock to one variable affects other variables over time. AW: st: finding the max of a variable and then using it. > > > > ds2 on SSC and in STB-56 is for Stata 6. What this means is that, in any given directory (ignoring its subdirectories), filelist will only return the first 10,000 files. The issue here is that the Mata function dir() has a hard-coded limit of 10,000 files it can return. If I drop the word "variable", it tells me "label not found". 10 different dependent variables explained by the same group of independent variables. I thought of storing values in label definitions, but it sounds like a kludge. The executive summary is given in the title. 3f `ProbF' local F_stat = 5. I have been trying to store multiple string values that begin with a blank space (i. I would like to loop over the variables, retrieve the -note- attached to each one, remove the stem, and then label the variable. We define a local variable which i which will store values from the Mar 30, 2022 · Forums for Discussing Stata; General; You are not logged in. /* create local list for variables that we want to add labels */ local variablelist "inc answer" To apply the new labels, you must decide how you would like the labels to look. A common need is a local containing all variables of a data set. Jan 8, 2021 · the variable hhid is a distinct household identifier that is the same for all the individuals in one household; the variable earner is 1 if the individual is an earner and 0 ottherwise; In that case something like the following untested code would do what you want. ) What I didn't get is why I could store the element [1,2] of my matrix m into a local macro, but I would like to evaluate the data sets to > see if certain variables are present before executing some code. For example: Code: clear cd "C:\Users\jannic\Desktop\sandbox" webuse grunfeld, clear keep if company <8 * the command below does not Mar 28, 2016 · - The names of these variables are of the form y1975winston, y1976winston, . However, I want to create a table with two columns (distribution & Gini coefficient) which shows the type of distribution and respective Gini in each row. Stata offers several types of looping constructs, with foreach and forvalues being the most  · Hi all, I had the same question as Daniel's but with an additional complication that makes Clyde's answer not work. I was running all out of the same . 1 on Windows 7, Home Premium, I have a str3 variable "country" which has three unique values (many Either way, remember > that locals are precisely that: local macros (which in Stata terminology > are _not_ variables at all) are local to their context, so you can't see > a local from outside. Dear Statalisters, I have, for example, two variables a1 and a2 of which the labels are: But does not work if I want to store the partial label in a local macro: Code: foreach May 9, 2016 · whereas when using-in-, instead, Stata will check only when trying to execute-sum `var'- whether the local macro `var' represents a variable of the current data I want to do a univariate analysis and to instruct stata to tabulate categorical variables and summarize continuous variables. If you store. I have found the following loop, but I am not sure how to adapt the variable names: foreach v of varlist _all{local x= variable label `v' rename `v' `x'}, but STATA tells me "variable not found". Feb 24, 2020 · The name of the variables other than "country" and "year" is equal to the final part of locals' name (e. >> variables: “x” and “y”. Apr 28, 2019 · If you want to save the scalars to new variables, you should use -gen- to create a new variable (all observations are the same constant). Notice that is there is no gain to just putting a value of a variable into a local macro and then 4 days ago · Using Local Macros for Looping. ' option on the database where the options are coded 0-13 (0=rash, 1=itchiniess, etc). Forecast how you will use macros in your own research. Recognize the difference between local and global Stata variables. So if you select the line "local controls age female educ wealth income children province_id commune_id village_id enum_id" and executes it, then it creates the local with the list of control variables, and when it is done, it removes that list again. 01%" 2"Fuelwood and traditional biomass: 27. I suppose because the variable names all have a long (and unnecessary) stem, they are stored as -note-s in the Stata dataset. From: Jeph Herrin <[email protected]> Prev by Date: st: RE: RE: adjusting variables in Mar 1, 2023 · As the title indicates I want to store a lot of variable names in a local, then use the local to produce summary statistics for the variables. Use Jun 11, 2018 · Good morning Stata-friends, I am currently puzzling with a rather complicated setting and I did not find any matching thread within the last hour. >> random vector. From: "Martin Weiss" <[email protected]> References: st: finding the max of a variable and then using it. Extract partial label of a variable in a local macro 30 Mar 2022, 05:41. Thank you. The equality sign tells Stata to store the evaluated result of the expression we specify (instead of storing that expression as a string). Try substituting the following code for your last code fragment: Ado-files use local variables. Here is an example using the lifeexp. local IT_2016_k_bfa in the "results dataset" I have a variable named k_bfa, while the first part of the local's name is given by the two variables "country" and "year" - we could think at these two variables as a sort of identifiers). Use the command local to create temporary macros. He in turn thanks Christopher F. In Stata, a macro is simply a named container that holds text. Here our new variables are in the form answer/year and inc/year. 1 2. Actually, I was referring to an example using your final code to solve a problem as the one you presented in #3. Technically, It works for regressions with smaller amount of independent variables, but my real working dataset has more than 30 variables and the regression will loop for at least 100 times ( I have a variable `Distance` which is in a range of (0 ~ 30,000) and I use it as `weight` as in the above example). And your conditions omit the case of `r(mean)' == 3000 (which, I know, does not happen in the auto. 4. You can browse but not post. Basically, what changes is the character in the middle, and since I'm working with several datasets and the characters change from one to another I've saved the list of My idea was to store all the names of the variables in a dataset in a macro variable, then evaluate that macro variable using "strpos" to see if the variable is present in the list, ending the code if strpos returns 0. You can post your data using -dataex- and tell the statalisters more about your intention so that others know how to help you. 1. 07%" 3"Electricity: 16. Nov 23, 2015 · `estout` will export everything and I need to edit them by myself. This local can be created by 4 days ago · In this blog post, I’ll explain the three main types of macros in Stata—local, global, and program. So `a' is not a "local variable", as it is not a column in a data-matrix. Store the Feb 7, 2018 · I am working with a data set on Stata 14 and would want to store numeric variables with two levels in the value labels (e. 5. e. You never showed the regression command itself, and it may be that you have omitted some options needed to get those results. 14" la var messy_var_3 "Some nonsense and figure that I need 20072014" * Jan 14, 2025 · Locals are an extremely useful object in Stata. Variable “x” goes from 1 to 100 and “y” is a. Feb 25, 2025 · 6macro—Macrodefinitionandmanipulation whichinturnisequivalentto global_a:tempvar global_b:tempvar global_c:tempvar tempfileisdefinedsimilarly. I'd like to be able to display the value of local variables in Do files for general troubleshooting purposes. Most Stata commands have hidden results stored after they are run. They aren't even of historic interest! Dec 13, 2017 · To clarify, filelist has no limit on the number of files it can handle and will happily scan your whole hard disk. 5497823654 local ProbF %9. Remarks and examples stata. See this post from 2015 that mentions the limit. 6973237484 local F_stat %9. "Context" here is a nonce expression for Stata > program OR main session OR do-file (including do-file editor). My > idea was to store all the names of the variables in a dataset in a > macro variable, then evaluate that macro variable using "strpos" to > see if the variable is present in the list, ending the code if strpos > returns 0. st: how to display value of local? From: econqian222 <[email protected]> Prev by Date: st: how to display value of local? Next by Date: st: estimating variables with constant change at each time period using Fixed Effects model; Previous by thread: st: how to display value of local? Next by thread: Re: st: how to display value of local? Index Apr 18, 2021 · Thank you, Joro Kolev. y2000winston, y1975walker, y1976walker,. dta data file. Local macros have a temporary scope, only existing within the specific command or do Re: st: How Can I Store a Variable's Label to Label Another Variable? where it comes from. But it keeps executing tabulate and summarize for all Jul 12, 2017 · Looking for some advice regarding replacing/recoding variable dependent on responses in other variables. I want to store For instances, let’s suppose that I have two. This is linked to Konrad's new question. txt I would like to create 3 variables in the file: identifier, date, form. Jan 5, 2025 · I don't know. Cox of the Department of Geography at Durham University, UK, and coeditor of the Stata Journal and author of Speaking Stata Graphics. 0 trying to store a variable value from one observation in a local macro (if the variable is a string) or in a scalar (if the variable is numeric). > > i have an abbreviated varlist stored in a local: > > local outcomes "an_abbreviated_varlist" > > i would like to create a new variable that contains the labels of the > variables in the abbreviated varlist (they are all labelled, the variables  · I don't know why you don't like your own approach, but if you have some kind of problem creating new permanent variables in your dataset and don't want to loop over observations, then you could create a temporary variable inside an ado-file that leaves the sum and average behind in returned scalars. " ST" " May 29, 2019 · 4levelsof— Levels of variable Acknowledgments The original version of levelsof was written by Nicholas J. Jan 15, 2025 · Dear Stata Users, I need your help in creating local macros for all three variables in the given dataset. 3f `F_stat' di `ProbF' `F_stat' Jan 23, 2015 · Hi fellow Statalisters, I'm writing a code which is supposed to store variables from survey data in a local. > > > > ds2 in STB-60 is for Stata 7. do window, but in a piecemeal fashion. list alpha 1. 10"Kerosene: 0. csv data gets exported to stata the column 'sideeffects_initial' reads 0 2 4 5 10 or 1 11 12 for example which stata reads as string because of May 19, 2015 · I was wondering whether there's a specific command for Stata 13. There are two types: local and global. I think this would be great for Stata users to know because many of us probably have already came across such a problem of Stata hitting the limits when using trying to define a local for a variable that contains too many different values. I would like to reference all variables using local or tokenize. 05 display `SigmaMax' Unfortunately, I couldn't find that the stata display the value of SigmaMax, so what's wrong with my program? Apr 25, 2018 · I want to use a local macro in a loop (foreach) that will eliminate the specified characters (including blank spaces) from matching string values in a variable. Doing this manually works. dta, but which you should provide for if this code is intended for use in a different context. >> Feb 7, 2018 · I am working with a data set on Stata 14 and would want to store numeric variables with two levels in the value labels (e. If you wanted to store the above as a string, the expression would be enclosed in inverted commas without the equality sign. . Jun 19, 2020 · Stata programs, usually, and other Stata code chunks, commonly, use local macros. 1 Stata Variables  · I would like to rename all variables by its label, but do not find the right command. From the limited knowledge I do know, local stores string or numerical values that can be later used to have a very clean do-file. This puts the numerical part of the variables into local macro <numnames>: unab vars : * foreach v of loc vars { loc numnames `numnames' `= substr("`v'", 2, . 1 on Windows 7, Home Premium, I have a str3 variable "country" which has three unique values (many observations): ABC, DEF, GHI. In this example, the local called local1 will store the value 10. I could use sum, detail and then use r(min) r(max), etc, or I could use egen var = min(var2) etc, but I would prefer to do this in one line if possible, because I don't need these variables, and I think keeping track of many tempvars will get messy. From: Pablo Bonilla <[email protected]> References: st: create local with specific value of a variable. 192) Best Daniel -- Hi, statalist I wrote the following brief program for stata, local SigmaMax = 131. " <[email protected]> Prev by Date: AW: st: finding the max of a variable and then using it; Next by Date: AW: st: finding the max of a variable and then Nov 25, 2016 · Forums for Discussing Stata; General; You are not logged in. Now, how can I save in a local the value of “y” when. Macroassignment Whenyoutype Oct 7, 2017 · I would like to create variables within a dataset using parts of the filename. 2. Mar 6, 2025 · local local1=5+5. This text can be Mar 6, 2025 · In Stata, macros are tools that store values for reuse. They are essential for automating repetitive tasks and are especially powerful when combined with macros. This is because I have of lot of different summary statistics for a lot of variable which need to be produced for a lot of different subpopulations, and I don't want to type out the variables every times. Note that findname has a local() option whereby a local macro can be created in the calling program's space, so an extra step of copying returned results to a local can be avoided. Ado-file programmers should use the Mata functions st_data() and Apr 19, 2017 · I want to create a table with my estimation results. foreach X of varlist inflation_r wages_a { generate `X'_1 = `X'/2 local label : variable label `X' label variable `X'_1 `"Half of `label''"' } See -help extended fcn-. > > Going beyond the example, using Dec 10, 2015 · Is there perhaps another way (except using local/global) to define groups of variables that can easily used in a number of regressions? E. local stratlist "`r(varlist)'" //store all strat vars in a local *di `"`stratlist'"'{ forval stratnum = 1/6{ local strat : word `stratnum' of `stratlist '" local variables `strata' `unobs' //putting observables and unobservables in one local di `"`variables  · I want to create a local containing sets of explanatory variables which are themselves stored as locals. i obtained what i > needed. > > > > ds3 on SSC is for Stata 7. Moreover, I want to have the label of the dependent variable as column title. As a simple example, the following code does not work: local ASDF = 1 Apr 18, 2021 · An easy solution is to save the levels not in a local, but rather in a new variables. Otherwise, you may also use local to store it in a macro. The following shows some ways to access the coefficients. Stata classifies it as scalars. From: "Data Analytics Corp. 00%" Feb 14, 2023 · Is there a good way to store these scalars in the same dataset? Creating a variable to store a scalar (gen var1=scalar1) does not seem an efficient solution since it stores many copies of the same value. See the following code: local y "wage income" foreach var in y{ivreg2 `y' age age_sq educ, cluster(id) est store olscomp`y', title(`:label variable `y'' sample1)} estout olscompwage olscompincome, label Jul 26, 2016 · Forums for Discussing Stata; General; You are not logged in. I would like to create a local list that includes all these variables, but excludes variables such as urb3. y2000walker, etc - All these variables are numeric variables Here is what I am trying to do: - I would like to label some of the existing variables, rename some of the existing variables and create new variables  · I used Stat/Transfer to convert a number of SPSS files to Stata files. Baum of the Department of Economics at Boston College and author Jun 9, 2020 · I simply save the Gini as a unique local and then list all the Gini coefficients. Re: st: create local with specific value of a variable. May 23, 2016 · Hello, I'm wondering if there is a way to save descriptive statistics in a local macro, in one line. Use the command global to create permanent macros. Loops in Stata: Loops are programming structures that allow you to repeat a set of commands multiple times with different values. Aug 10, 2020 · Hi everyone! I'm a grad student with a few years of experience with Stata. May 28, 2019 · I am trying to format some locally saved variables (that's fine so far) and then to output these in a text string. I would do it like this: local price "price" sysuse auto, clear unab vars: _all local ok : list price in vars if `ok' { do whatever you want to do with price } sysuse nlsw88, clear unab vars: _all local ok : list price in vars if `ok' { in this dataset price is absent so this block won't be executed } Hope this helps, Maarten --- Tim Wade <[email protected]> wrote: > Hi Statalisters: > > I Apr 12, 2016 · The code `=_N' evaluates the number of observations on the fly, so that the loop code sees an actual number 42, or 666, or 7 billion, or whatever. local local_for_legend "1 "First variable label" 2 "Second variable label"" Stata will interpret the inner quotation marks as Sep 14, 2018 · I would like to store the regression coefficients and standard errors (_b and _se) from regressing multiple y variables on the same x variable. For instance sysuse auto, clear local f0: label origin 0 di "`f0'" will get you want you want. Login or Register by clicking 'Login or Register' at the top-right of this page. scalar list Sep 25, 2016 · Forums for Discussing Stata; General; You are not logged in. Say that now `n' has the string "bear" stored in it. That is not what you want. Consider the When a program or do-file ends, its local macros are permanently deleted. Save maximum of a variable as local variable? as described in the title I would like to store the maximum of a variable across all observations. Feb 5, 2020 · sysuse auto local loclist "" foreach v of varlist weight headroom foreign { quiet sum `v' local s_`v' = r(sum) // save the value of interest in a local // Add name of this local to a list. When . g Yes/No, Male/Female, Increase/Decrease) in a local to use them later in a do file. Options are things that are placed after the comma in a command, so -if- is not an option. Oct 28, 2024 · Whenever, we run summ command, Stata stores some additional statistics in its memory. Of course that's dopey, as list varname gets you there, but it's understood that your example is proxy for your real problem. I have never done something like this and my use of locals was my best guess as a starting point. Nov 28, 2018 · But, to use st_store(), what's needed here, to my understanding, is to create the variable(s) in Stata before using st_store(). Dec 10, 2014 · data variable or a scalar), Stata selects the one feasible solution and does it. I cannot get the code to work because Stata does not allow "if" when defining locals Jan 22, 2021 · I have a dataset with many lengthy variable names but which are useful for identification. The lines in italics behind each ">" show what Stata output I receive. Apr 12, 2016 · Forums for Discussing Stata; General; You are not logged in. Here's what I played around with. And lastly, a more complete example of how multiple locals can be used in an iterative process with regular expressions. Unlike Mata, Stata does not allow users to create matrices containing string values. -clonevar- was My idea was to store all the names of the variables in a dataset in a macro variable, then evaluate that macro variable using "strpos" to see if the variable is present in the list, ending the code if Apr 7, 2015 · I am running Stata 12. So you might be Jan 15, 2020 · Since I am using the loop to avoid typos, it seems like it would be a good idea to store the output of the loop in a macro, and then stack the macro as opposed to risking typos by listing each variable. Otherwise this is the story: > > > > ds5 on SSC is for Stata 5. Create local variable list with * 25 Nov 2016, 03:30. kplaj woqudd dnkau vdwv wkwvj poxe abrsz okf sdhvo twhrb xqk amdtjew mbes gvtskkg twmet