Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Proc NLMIXED Covariance and Correlation

Options

- RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

🔒 This topic is **solved** and **locked**.
Need further help from the community? Please
sign in and ask a **new** question.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Posted 10-29-2018 12:16 PM
(2929 views)

I have been trying a few different models with different functions but NB distribution. However, in one of the functions that I use, in my results, I get covariance matrix and correlation matrix of parameter estimates even though I did not use CORR or COV function.

What could possibly be the reason for me to obtain such output in one function but not in others? Attached is the output.

Is there any statistical problem in the function?

Any form of help would be highly appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

> What could possibly be the reason for me to obtain such output in one function but not in others?

> Is there any statistical problem in the function?

That is an interesting question. I am not 100% sure, but based on some testing I believe that the COV/CORR matrices will be displayed when

1. The model converges, but

2. The Hessian at the solution "has a problem."

Thus when they print, the procedure is encouraging you to look closely at the solution. There is something unusual about it.

The "problem" might be that it is not positive definite or that it is not invertible.

In my tests, one situation where I see the COV/CORR matrices when I am doing a constrained optimization and the optimal solution is on the boundary of the constraint region. In that case, the optimal solution is not a point where the gradient vanishes, and so the Hessian at the solution might not be positive definite.

4 REPLIES 4

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

> What could possibly be the reason for me to obtain such output in one function but not in others?

> Is there any statistical problem in the function?

That is an interesting question. I am not 100% sure, but based on some testing I believe that the COV/CORR matrices will be displayed when

1. The model converges, but

2. The Hessian at the solution "has a problem."

Thus when they print, the procedure is encouraging you to look closely at the solution. There is something unusual about it.

The "problem" might be that it is not positive definite or that it is not invertible.

In my tests, one situation where I see the COV/CORR matrices when I am doing a constrained optimization and the optimal solution is on the boundary of the constraint region. In that case, the optimal solution is not a point where the gradient vanishes, and so the Hessian at the solution might not be positive definite.

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Hi Rick,

So these were the notes in the Log file

NOTE: Convergence criterion (GCONV=1E-8) satisfied.

NOTE: At least one element of the gradient is greater than 1e-3.

NOTE: Moore-Penrose inverse is used in covariance matrix.

WARNING: The final Hessian matrix is not positive definite, and therefore the estimated covariance

matrix is not full rank and may be unreliable. The variance of some parameter estimates is

zero or some parameters are linearly related to other parameters.

I came across an article which says that when above warning appears the results are not reliable. What are alternatives or other approaches to run the model without such errors?

Thank you for your response!

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Your article should have mentioned that lack of convergence often indicates that the model does not fit the data. So alternatives to "run the model without such errors" include

1. Choose a model that fits the data better

2. Get more data, if the sample size is very small

- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content

Thank you.

**SAS Innovate 2025** is scheduled for May 6-9 in Orlando, FL. Sign up to be **first to learn** about the agenda and registration!

What is ANOVA?

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.