[R] nlrq coefficients querry

From: Jeremy VanDerWal <jjvanderwal_at_gmail.com>
Date: Wed, 16 Jan 2008 12:28:40 +1000


I have been quantreg library for a number of projects but have just hit a snag. I am using nlrq to examine an asymptotic relationship between 2 variables at the 99th percentile. It performs as expected, however when I try to extract the coefficients along with se and significance I am running into problems. The problem is that for the nlrq regression Dat.nlrq, summary(Dat.nlrq) reports a different coefficients table than summary( Dat.nlrq)$coefficients.

Below is a series of syntax (mostly from the nlrq sample script) reproducing the error.

########################################################
# get the necessary libraries

library(quantreg)

#code from the example of nlrq documentation
Dat <- NULL; Dat$x <- rep(1:25, 20)
set.seed(1)
Dat$y <- SSlogis(Dat$x, 10, 12, 2)*rnorm(500, 1, 0.1) plot(Dat)

Dat.nlrq <- nlrq(y ~ SSlogis(x, Asym, mid, scal), data=Dat, tau=0.975, trace=TRUE)
lines(1:25, predict(Dat.nlrq, newdata=list(x=1:25)), col=4)

#code demonstrating the error...

print(summary( Dat.nlrq))
print(coef(Dat.nlrq)) #coefficients are the same as above
print(summary(Dat.nlrq)$coefficients) #coefficients differ from previous 2
commands
########################################################

I am using R2.5.1 with quantreg 4.10 on an 64-bit xp system. I have verified this same error occurs on an 32-bit xp system.

Any suggestion to correct this, or as a work-a-round would be greatly appreciated.

Cheers,

Jeremy

        [[alternative HTML version deleted]]



R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Wed 16 Jan 2008 - 02:32:41 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 16 Jan 2008 - 04:30:07 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive