Dear STATA members,
I am struggling to pot a linear regression model- model 1) with the outcome variable (depression score) and the main predicting variable (gender norm score) and model 2) the same outcome and predicting variables but adjusted for other covariates (e.g. sex, age, pornography, etc)> here are the commands. GSV means gender stereotypical views which are one of the gender norm composite score. This and the outcome variable are both continuous variables.
reg meanscore_depression_withoutmiss meanscore_gsv_withmiss
margins, at(meanscore_gsv_withmiss = (0(1)5))
margins, at(meanscore_gsv_withmiss = (0(1)5)) plot
reg meanscore_depression_withoutmiss meanscore_gsv_withmiss peer_violence_per peer_violence_vic i.aces_cat3 i.safety_school i.ia2gender age_con i.anydrug i.male_friends i.female_friends3 i.via4_pornography i.expect_school2 i.parent_awareness
margins, at(meanscore_gsv_withmiss = (0(1)5))
margins, at(meanscore_gsv_withmiss = (0(1)5)) plot
The graphs that I could get from these syntaxes are attached in this message.
My questions:
1) is this the right way to plot the linear regression models? (there is no significant interaction, my objective is to show the curve / graph when the model was adjusted to other covariates than gender norm score)
2) Do someone know if there is any way to plot these two graphs in one single graph? That would be easier for the readers to compare the graph from the two models.
Thanks so much for your help in advance,
Rinko
I am struggling to pot a linear regression model- model 1) with the outcome variable (depression score) and the main predicting variable (gender norm score) and model 2) the same outcome and predicting variables but adjusted for other covariates (e.g. sex, age, pornography, etc)> here are the commands. GSV means gender stereotypical views which are one of the gender norm composite score. This and the outcome variable are both continuous variables.
reg meanscore_depression_withoutmiss meanscore_gsv_withmiss
margins, at(meanscore_gsv_withmiss = (0(1)5))
margins, at(meanscore_gsv_withmiss = (0(1)5)) plot
reg meanscore_depression_withoutmiss meanscore_gsv_withmiss peer_violence_per peer_violence_vic i.aces_cat3 i.safety_school i.ia2gender age_con i.anydrug i.male_friends i.female_friends3 i.via4_pornography i.expect_school2 i.parent_awareness
margins, at(meanscore_gsv_withmiss = (0(1)5))
margins, at(meanscore_gsv_withmiss = (0(1)5)) plot
The graphs that I could get from these syntaxes are attached in this message.
My questions:
1) is this the right way to plot the linear regression models? (there is no significant interaction, my objective is to show the curve / graph when the model was adjusted to other covariates than gender norm score)
2) Do someone know if there is any way to plot these two graphs in one single graph? That would be easier for the readers to compare the graph from the two models.
Thanks so much for your help in advance,
Rinko
