I regressed x1 and x2 on y seperately and jointly. After the joint regression, I want to compare the strength of both variables and which of them correlates stronger with y.
Before I standardize the variables.
egen x1_1=std(x1)
egen x2_1=std(x2)
reg y x1_1 x2_1, robust
test x1=x2
( 1) x1_1 - x2_1 = 0
F( 1, 129) = 62.66
Prob > F = 0.0000
So, the H0 the test equal command is that the variables are equal. Since H0 is rejected I can say that x1 and x2 are significantly different from each other. But I cannot say whether one of them is stronger right? Can I determine that by comparing the correlation coefficients then?
Thanks in advance.
Related Posts with comparing the magnitude of two independent variables
Appending several datasets for selected variables in the master datasetI have datasets for 12 countries containing a multitude of variables e.g. age, sex, tobacco use, alc…
LCA(Latent Class Analysis) still "not concave" and No Results in "gsem"Dear Friends, I tried to use LCA in stata15 for my paper. I want to classify the observed people int…
Create country dummies and time count variable – Panel data regressionHi all! I am trying to create country dummies and a time count variable (en variable for each year …
Loop over multiple observations in one variableHi, I am trying to find out mean of rainfall for period of 30 years for each of the 140 countries. …
logistic regression for categorical variablesHi! I have a variable gender (0=Male, 1=Female) and I am trying to run a logistic regression with "f…
Subscribe to:
Post Comments (Atom)
0 Response to comparing the magnitude of two independent variables
Post a Comment