Re: [R] Singular design matrix in rq

2013-04-19 Thread William Dunlap
:29 AM > To: Koenker, Roger W > Cc: r-help > Subject: Re: [R] Singular design matrix in rq > > Roger: > > Doh! Just realized I had that error in the code -- raw_data is the same as > mydata, so it should be: > > mydata <- read.csv("singular.csv") > plot(

Re: [R] Singular design matrix in rq

2013-04-19 Thread Jonathan Greenberg
Roger: Doh! Just realized I had that error in the code -- raw_data is the same as mydata, so it should be: mydata <- read.csv("singular.csv") plot(mydata$predictor,mydata$response) # A big cloud of points, nothing too weird summary(mydata) # No NAs: # Xresponse predict

Re: [R] Singular design matrix in rq

2013-04-19 Thread Roger Koenker
Jonathan, This is not what we call a reproducible example... what is raw_data? Does it have something to do with mydata? what is i? Roger url:www.econ.uiuc.edu/~rogerRoger Koenker emailrkoen...@uiuc.eduDepartment of Economics vox: 217-333-4558

Re: [R] Singular design matrix in rq

2013-04-18 Thread William Dunlap
alues then use fewer degrees of freedom in bs(). Bill Dunlap Spotfire, TIBCO Software wdunlap tibco.com From: jgrn...@gmail.com [mailto:jgrn...@gmail.com] On Behalf Of Jonathan Greenberg Sent: Thursday, April 18, 2013 6:50 AM To: William Dunlap Subject: Re: [R] Singular design matrix in rq Wi

Re: [R] Singular design matrix in rq

2013-04-16 Thread William Dunlap
Have you looked at the result of bs(raw_data[,i], df=15) ? If there are not many unique values in the input there will be a lot of NaN's in the output (because there are repeated knots) and those NaN's will cause rq() to give that message. E.g., > d <- data.frame(y=sin(1:100), x4=rep(1:4,each=2