Can I ignore this warning? If not, any suggestions on what to check.
I get this error message with a ZINB model but not with a ZIP model with the same terms.
A search of the Internet for "negative of hessian not positive definite" returns a number of discussions on this issue.
@Rick_SAS wrote a blog about it . In general, your model is not specified correctly or your initial value is not good.
There was one variable in my zinb model that came out with a missing Wald Chi-Square. I reran with that variable removed and the error went away, but I have still have missing Chi-Square values in my Type 3 table. Is this also a sign of misspecification?
Please show us the output.
I dropped variable F from my zero model and the warning went away, but my type 3 tables look like this:
LR Statistics For Type 3 Analysis | |||
Source | DF | Chi-Square | Pr > ChiSq |
a | 5 | 4184.93 | <.0001 |
b | 1 | 3.38 | 0.0662 |
c | 1 | 833.46 | <.0001 |
d | 1 | . | . |
e | 1 | 1303.81 | <.0001 |
f | 1 | . | . |
g | 1 | 1156.32 | <.0001 |
h | 1 | 110.49 | <.0001 |
i | 1 | 35.01 | <.0001 |
j | 4 | . | . |
k | 2 | 284.19 | <.0001 |
l | 3 | 577.5 | <.0001 |
m | 1 | . | . |
n | 1 | . | . |
o | 1 | 592.15 | <.0001 |
p | 1 | 521.37 | <.0001 |
q | 1 | 1572.42 | <.0001 |
r | 1 | 877.94 | <.0001 |
LR Statistics For Type 3 Analysis of Zero | |||
Inflation Model | |||
Source | DF | Chi-Square | Pr > ChiSq |
a | 5 | 105.13 | <.0001 |
b | 1 | 57.31 | <.0001 |
c | 1 | 101.84 | <.0001 |
d | 1 | 8.43 | 0.0037 |
e | 1 | 47.75 | <.0001 |
g | 1 | 2.99 | 0.0839 |
h | 1 | 0.19 | 0.6623 |
i | 1 | 1.5 | 0.2212 |
j | 4 | 295.27 | <.0001 |
k | 2 | . | . |
l | 3 | . | . |
m | 1 | . | . |
n | 1 | 15.08 | 0.0001 |
o | 1 | 15.55 | <.0001 |
p | 1 | 0.09 | 0.7666 |
q | 1 | 27.7 | <.0001 |
r | 1 | 15.6 | <.0001 |
Please read message 3 in this thread: https://communities.sas.com/t5/Statistical-Procedures/Interpreting-Multivariate-Linear-Regression-wi...
Although that discussion was about logistic regression, the concept applies to all modeling in SAS with a CLASS variable(s).
In addition, you probably can't estimate all of the factors in your model, as they are not independent of one another, if you know an estimate of one coefficient, you can determine the estimate of other coefficients.
But these aren’t levels of a categorical variable, they are each separate categorical variables. This isn’t a parameter estimates table like in the link, it is a type 3 table.
Would the lack of independence show up in VIF/TOL type statistics?
Suppose you have temperature (Celsius) and temperature (Fahrenheit) and temperature (Kelvin) as three variables, and you want to put them all in the model. These are not independent, these are completely dependent, if you know one, you know the others exactly, and after putting one of these in the model, there's no additional information to be gained by putting the others in the model. That's the situation you are in, that is why some of the variables cannot be estimated by your model.
I would think that would show up as high correlation or high VIF, but I don't see any correlations above .25 and all VIFs are below 2. Also why does this show up in the ZINB model but not the ZIP model?
This can also happen if one variable is a linear combination of other variables. Such as
x4 = 0.25*x1 - 2.75*x2 + 61*x3
and if this is the case, you still can't estimate the effect of x4, even though the correlation might not indicate a problem. Or it may be something specific to ZINB, but I don't know enough about ZINB to be sure.
Please show your PROC GENMOD statements.
proc genmod data = temp
class bene_id a b c d
e f g h i j
k l m n o p q r;
model &outcome. = a b c d
e f g h i j
k l m n o p q r / dist = zinb link = log offset=logofsomething type3;
zeromodel a b c d
e f g h i j
k l m n o p q r;
run;
removing f from the zeromodel removes the error but leaves me with blanks in my type 3 table.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.