Hello
I urgently need help with the loop function in STATA to order multiple variables together.
In my dataset, I have gender, region, race, database (+200 other variables) and their encoded counterparts at the bottom namely gender01, region01, race01, database01.
I want to put all numeric variables after their string counterparts like the following:
gender, gender01, region, region01, race, race01 and so on.
I know how to do 1 by 1 but it should be possible to do them all together.
Any help will be highly appreciated.
Thank you.
Related Posts with Loop function to order multiple variables together
Code to get Beta coefficients in multiple imputation models in Linear regressionWhat's the code to get Beta coefficients in multiple imputation estimate models in Linear regression…
Histograms in loopHello Sir Have some issues with including titles in histograms in a loop. The code is running but n…
Working paper on entropy balancing and update to -ebalfit-A working paper describing the methods used in ebalfit is now available from https://ideas.repec.org…
Combining exact and propensity score matchingHi all, Would appreciate help with matching on propensity score within bins. I have either: Code…
Creating new IDs with a set number of observationsHello all, I am trying to run a simulation on a dataset that contains user reviews. I have a select…
Subscribe to:
Post Comments (Atom)
0 Response to Loop function to order multiple variables together
Post a Comment