Hello,
I am very new to Stata - I have tried reading around to solve my error but I am struggling! I am using StataIC 16.
I am trying to run a regression for log hourly wages on various variables, many of which are factor variables. I have downloaded data from the labour force survey.
Regression:
reg LGHOURPAY AGE b(5).DEGCLS7 b(1).EMPLEN b(1).ETHUKEUL b(0).FDPCH16 b(9).FORTYP15 b(2).FTPTWK b(8).GORWKR b(15).IN0792SM b(1).MARSTA b(1).MPNR02 b(2).PUBLICR b(9).SC10MMJ b(1).SEX b(6).SNGDEGB
This is my regression and I believe the b(). allows me to choose what base/ reference level for the factor variables. However, I am getting the "Factor Variables may not contain negative values" error code. I have looked and the "don't know" levels for each variable have group number of -9.
How would I overcome this problem?
Thanks!
Related Posts with Stata error code: Factor Variables may not contain negative values
How to store multiple regression resultsHello, I am currently running a Vector autoregression with 5 lags and 4 exogenous variables. I have …
META-ANALYSIS without standard-deviationsI am trying to perform a meta-analysis estimation with data from studies using different methodologi…
How to do two part model when there is one independent variable is binary and endogenous?I want to use the two-part model to estimate food expenditure (Y), in the Xs, one variable is endoge…
regexmHi STATALIS I want to select patients with "IAM" in the studydescription_all variable . The "studyd…
How to sample with unequal probability in a given populationHi Statalist experts, Suppose I have data on a population of N subjects, each has X1-X5 and and var…
Subscribe to:
Post Comments (Atom)
0 Response to Stata error code: Factor Variables may not contain negative values
Post a Comment