My dataset comes from a survey with 5 waves that has a general score (variable GScore). I am trying to do the following:
1) I am trying to generate a new variables that shows the General Score increase from each wave to the next (so that a decrease in scores will be a negative value). What code would work best for this? I am currently trying to use the following unsuccessfully:
bysort id: gen GScore_increase = GScore - GScore[_n-1]
2) What code would calculate the overall mean increase (or potential decrease) in the GScore across all waves for all participants?
3) Is there an efficient code I could use to determine how many participants decreased or maintained the same GScore across all waves (i.e. how many never increased their Gscore across all the waves)?
Related Posts with Generating Variable That Depicts Increase
Matching: Conditioning on lagged dependent variablesHi everybody, I wondered whether it does make sense to condition on the lagged dependent variable w…
Quantify the effect size of an interaction termHello, I have a doubt that it is not specific about Stata. However, I would like to ask you for an…
Trajectory Analysis in longitudinal dataDear Altruists, Good morning. Any suggestions for performing trajectory analysis for longitudinal ob…
Power Analysis [power] in Context of Regression Analysis and Robust Standard ErrorsHi, Based on the results of a regression analysis, I would like to perform a power analysis that ac…
Grouped Difference of Mean TestDear all, I want to perform a difference of means test on my dataset, to see whether there is a dif…
Subscribe to:
Post Comments (Atom)
0 Response to Generating Variable That Depicts Increase
Post a Comment