[R] error in La.svd Lapack routine 'dgesdd'

Millo Giovanni Giovanni_Millo at Generali.com
Thu May 3 16:27:07 CEST 2012


Dear Philipp,

this is just a tentative answer because debugging is really not possible
without a reproducible example (or, at a very bare minimum, the output
from traceback()).
Anyway, thank you for reporting this interesting numerical issue; I'll
try to replicate some similar behaviour on a similarly dimensioned
artificial dataset when I have some time (which might not be soon). As
for now, please see below my remarks with '##', I hope they are useful
anyway. Bottom line: time fixed effects might be out of place here.

Best wishes,
Giovanni

Giovanni Millo, PhD
Research Dept.,
Assicurazioni Generali SpA
Via Machiavelli 4,
34132 Trieste (Italy)
tel. +39 040 671184
fax  +39 040 671160

----------------- original message ------------

Message: 8
Date: Wed, 2 May 2012 05:45:47 -0700 (PDT)
From: Philipp Grueber <philipp.grueber at ebs.edu>
To: r-help at r-project.org
Subject: Re: [R] error in La.svd Lapack routine 'dgesdd'
Message-ID: <1335962747113-4603097.post at n4.nabble.com>
Content-Type: text/plain; charset=UTF-8

Dear R Users,

I have an unbalanced panel with (on average) approx. 100 individuals
over
1370 time intervals (with individual time series of different lengths,
varying between 60 and 1370 time intervals). I use the following model:

	res1<-plm(x~c+d+e,data=pdata_frame, effect="twoways",
model="within",
	na.action=na.omit))

## I have difficulty in understanding why you would want to introduce
ca. 1470 incidental parameters... I'd rather go with a more parsimonious
specification: a trend, AR(n) or else...

I repeatedly get the following error (which has been discussed in the
past):

	Error in La.svd(x, nu, nv) : error code 1 from Lapack routine
?dgesdd?

I found it hard to create a reproducible example. As noted by Douglas
Bates,
the error might be related to the scaling of the matrix. 

## Too difficult for me to tell without output, references etc.,
although of course I trust D.B.'s opinion. 

For variables x,c,d,and e in object pdata_frame, I find that all sd()
are
reasonably similar both among the cross-sections as well as among the
variables. However, I find that extracting the demeaned data from plm(),
variables demXt$d and demXt$e (i.e. the demeaned variables) have sd()s
that
are very small compared to those of dem_yt and demXt$c (approx. by
factor
1e-15). I extract the demeaned data as follows:

dem_yt<-pmodel.response(res) 
demXt<-model.matrix(res)

How is this possible? What is it that plm() does with my data so that
the
standard deviations change? 

## it demeans them... (although the scale of the reduction is
impressive, yet you're estimating out 1500 constants!)

I suspect effect="twoways" to play a central role because plm() works
fine
for effect="individual". 

## sure, also because "individual" 'just' introduces 100 more
parameters.

I thought about the idea that maybe, time-effects
simply do not apply here. 

## You know your model. Yet time effects on T=1300 seems hazardous to
me.

However: In order to test my regression for
time-effects (which I detect for subsamples (by time) and for equation
x~e
at high levels of significance), I need both the model with and and the
model without time effects (as otherwise, I can't compare the two models
in
an F-test), right? Any alternative tests? 

## please see ?plmtest

Another thought was that the impact of d and e changes over time (as in
the
subsamples I do see such a change).

Any help is appreciated!

## HTH, G.

Best wishes,
Philipp Grueber

-----
____________________________________
EBS Universitaet fuer Wirtschaft und Recht
FARE Department
Wiesbaden/ Germany
http://www.ebs.edu/index.php?id=finacc&L=0
--
View this message in context:
http://r.789695.n4.nabble.com/error-in-La-svd-Lapack-routine-dgesdd-tp21
25052p4603097.html
Sent from the R help mailing list archive at Nabble.com.


 
Ai sensi del D.Lgs. 196/2003 si precisa che le informazi...{{dropped:12}}



More information about the R-help mailing list