Dear all,
Y is a dummy variable (1 - crises occur, 0 - crises).
I have to crate a new variable X, that x =1, if within next 24 months a crises occur (in the next 24 month, Y has 1).
How can I code that X is searching in Y value from (A1:A24) in Stata?
Could you kindly help me.
Related Posts with How to create new variable X=1, if Y=1 in the 24 cells (A1:A24), and X=0, if in the 24 cells (A1:A24) =0
Correcting the condition for the creation of a new variable based on a duration since an initial assessementHello All, I hope this message finds you well! I have longitudinal unbalanced data and I am trying…
Re-coding 2 race/ethnicity variablesHello, I have a survey with 2 variables related to race/ethnicity I need to re-code. The first (lab…
Is it posible to make a math formula on a twoway tab?Hi. I'm having a little problem with the tab option. I have data that is presented like this: REG…
mibeta interpretationI have a question regarding the output that I get with the mibeta commad. I ran mibeta on multiple i…
Factor variable notation: How to omit the base period in event study?Hello everybody, I am trying to run an event study model, i.e. I want seperate coefficients of a co…
Subscribe to:
Post Comments (Atom)
0 Response to How to create new variable X=1, if Y=1 in the 24 cells (A1:A24), and X=0, if in the 24 cells (A1:A24) =0
Post a Comment