I have a database with three variables: 27 states, 10 years and a GDP for each year. I want to generate a variable with the resulting logical operation: if year=2017, then GDP*2 & if year=2018, then GDP*7 & if year=2019, then GDP*15, and so on.
How can I do that, please?
Related Posts with Logical operation using generate
-moremata- update: improved entropy balancing algorithmAn update to the moremata package is now available from SSC. Type Code: . ssc install moremata, re…
regression loop !Dear Colleagues I have daily stock returns and market return for 100 firms and for a number of year…
fixed effect regression with unbalanced panelDear Statalisters, I would like to do a fixed effect regression using 28 European countries across …
Addtions of observations with conditionsHello everybody, I have a big dataset to manage and I'd like to reduce it. To do so, I want to add …
PSM model (3d time)Hello every one please i have a big difficulty with propensity score matching model, i understood th…
Subscribe to:
Post Comments (Atom)
0 Response to Logical operation using generate
Post a Comment