Hello everyone, Hope you all feeling well. I need help in the following specific case in STATA:
First I wanna give you background about my question, which is mentioned below:
Dependent Variable = Y
Independent Variables = X1, X2, X3, X4
X1 = contain categorical values (0, 1)
X2 = contain categorical values (1, 2, 3, 4, 5)
X3 = contain categorical values (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)
X4 = contain categorical values from 30 to 80
I Labelled all my categorical variables like below:
X1:
0 = F
1 = M
X2:
1 = SS
2 = JC
3 = UG
4 = PG
5 = PD
X3:
Below 1 values: = B1
between 1 and 5 = U15
between 5 and 10 = U510
Above 10 = A10
X4:
Below 30 = B30
Between 30 and 40 = B3040
Between 40 and 50 = B4050
Between 50 and 60 = B5060
Above 60 = A60
By regressing, I find the below results:
Y Coef. Std. Err. z
X1:
0: 0.3534 0.332 0.234
1: 0.4543 0.245 0.132
X2:
1 0.4534 0.245 0.543
2 0.6457 0.652 0.767
3 0.2465 0.124 0.232
4 0.6634 0.543 0.657
5 0.7532 0.123 0.232
X3:
Under 1: 0.9506 0.545 0.564
between 1 and 5 0.8474 0.231 0.234
between 5 and 10 0.6767 0.235 0.576
Above 10 0.4575 0.232 0.898
X4:
Below 30: 0.8678 0.646 0.876
Between 30 and 40 0.2346 0.576 0.657
Between 40 and 50 0.6544 0.786 0.567
Between 50 and 60 0.4322 0.574 0.256
60 Plus 0.3235 0.345 0.245
Label command replace original values by below: (suppose in case of X2)
label define X1o 1 SS 2 JC 3 UG 4 PG 5 PD
MY PROBLEM:
by label command, each variable replace it's original value with 1, 2, 3, 4 or 5. Mean to say by labeling the independent variables, the dependent variable (Y) then regress not by original values of X1, X2, X3 and X4 but replace value, which shows against theory results.
"NOW MY QUESTION IS"
Is it possible that Y regress on the categories of X1, X2, X3 and X4 original values ??
Thanks for stopping by.
Related Posts with Categorical Variables Treatment at Regression Analysis
STATA commands for Factor analysis with robust covariance matrixHi Statalist members Does anyone know what STATA commands/ set of commands can be used to run a fac…
Make a loopHi, I'm very bad making loops I tried to export and generate variables in this way. I have to do th…
Children Height Velocity measurementHi, I’m looking for a Stata package to measure the percentile or standard deviation of height veloc…
Rearrange dataset - reshape or transposeI would like to reshape or transpose the following dataset in a panel data with "Code" as firm ident…
Table interpretation - outreg2Hi all, Is it possible to say that when V1 increase, V2 will increase too. or how can i interpret t…
Subscribe to:
Post Comments (Atom)
0 Response to Categorical Variables Treatment at Regression Analysis
Post a Comment