Hello everyone,
I have a variable named "diversity" (and a bunch of other variables) and I would like to drop the values of the variable "diversity" if the value of diversify is less than 0 (without dropping the values of other variables).
I tried the below command but I get "invalid syntax" error.
command:
drop diversity if diversity<0
Could someone please advise on how to perform this?
Thanks,
Ama
Related Posts with Drop the values of a variable with if condition
stacked bar chartHi, I have a dataset of sales that can be attributed to one of three buyer-organizations (1,2,3). T…
Comparison of the dataHello room, Am struggling to do variation comparison between variables. What is the best method to …
Testing multiple coefficients equal to 1 with testHi all. I am running a panel regression with over 60 dummy variable coefficients that I'd like to te…
Treatment of missings in geodistI have encountered the following issue using geodist from SSC, by Robert Picard: When all coordinate…
Fusing multiple rows into a single columnHello, I am a beginner using Stata 15. I have a data in the long format which I will like to convert…
Subscribe to:
Post Comments (Atom)
0 Response to Drop the values of a variable with if condition
Post a Comment