Hi all,
so i have a numeric variable with a lot of values, that are decimal:
4,626276
5,162374
5,612217
etc.
The lowest value is 4,626276 and the highest value is 79,43243.
Now, I want to reverse the variable so that it runs from highest to lowest (so that 79,43243 is the first value and 4,626276 the last value). I did it with the revrs command: revrs mcs_1st (mcs_1st is the name of the variable).
But now the problem: This isn't actually reversing the variable. So the new variable is the same as the old one.
So my question is? How can I reverse the variable without revrs? Is there a way?
I hope you understand what I mean.
Related Posts with Reverse a numeric variable
RDD rdrobust problemDear all, I am researching the effect of grade retention on exam results (which can vary from 0 to …
Mediation analysis with binary outcomeHello everyone! I built a gsem model in the SEM builder where I had 1 continuous indepedent, 1 conti…
Which method do I need for my research project?Hi guys, currently I'm working on a research project... or at least I try to find out if it is suit…
Generate variables with ratios of subgroup valuesHello! I got stuck solving a problem which must be very simple to address, apologies if I am overloo…
Data input: Please help!How do I answer this questions using stata. 1. Describe your sample i.e. provide sample characteris…
Subscribe to:
Post Comments (Atom)
0 Response to Reverse a numeric variable
Post a Comment