Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
X is rank deficient to within machine precision.

Subject: X is rank deficient to within machine precision.

From: Michele Costola

Date: 31 Oct, 2009 09:56:02

Message: 1 of 4

Hi everybody,
I'm doing regression on my y with x serie with 15 lag, so I have 17 column (const+1+15) in my x. When I start the regression I get this error:

Warning: X is rank deficient to within machine precision.
> In regress at 82

I tried to search on the newsreader but I don't really understand what could be the problem and how to solve it.
Thank you for your support,
Michele

Subject: X is rank deficient to within machine precision.

From: Peter Perkins

Date: 2 Nov, 2009 13:26:21

Message: 2 of 4

Michele Costola wrote:
> Hi everybody,
> I'm doing regression on my y with x serie with 15 lag, so I have 17 column (const+1+15) in my x. When I start the regression I get this error:
>
> Warning: X is rank deficient to within machine precision.
>> In regress at 82

Most likely you have too many predictor variables, and too few observations. As an alaogy, imagine trying to fit a cubic polynomial regression with only two observations. REGRESS will make a choise about which coefficients to set to zero, but it can't possibly know what you really want.

Hope this helps.

Subject: X is rank deficient to within machine precision.

From: FG

Date: 9 Jan, 2012 20:35:09

Message: 3 of 4

This is likely multicollinearity. if you the variables are dummies, remember to leave out one of the dummies as the model's intercept will pick up the dummy you leave out as the base model.


Peter Perkins <Peter.Perkins@MathRemoveThisWorks.com> wrote in message <hcmmlt$lqh$2@fred.mathworks.com>...
> Michele Costola wrote:
> > Hi everybody,
> > I'm doing regression on my y with x serie with 15 lag, so I have 17 column (const+1+15) in my x. When I start the regression I get this error:
> >
> > Warning: X is rank deficient to within machine precision.
> >> In regress at 82
>
> Most likely you have too many predictor variables, and too few observations. As an alaogy, imagine trying to fit a cubic polynomial regression with only two observations. REGRESS will make a choise about which coefficients to set to zero, but it can't possibly know what you really want.
>
> Hope this helps.

Subject: X is rank deficient to within machine precision.

From: Dinakar

Date: 7 Mar, 2014 04:07:08

Message: 4 of 4

You have an extra intercept - you dont need both const and 1. Drop one and see.

Regards
Dj

"mklcst mklcst" wrote in message <hch1ji$1g0$1@fred.mathworks.com>...
> Hi everybody,
> I'm doing regression on my y with x serie with 15 lag, so I have 17 column (const+1+15) in my x. When I start the regression I get this error:
>
> Warning: X is rank deficient to within machine precision.
> > In regress at 82
>
> I tried to search on the newsreader but I don't really understand what could be the problem and how to solve it.
> Thank you for your support,
> Michele

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us