[R] Error in Switch in KhmaladzeTest

xiaolu.x.ren at us.hsbc.com xiaolu.x.ren at us.hsbc.com
Wed Oct 15 17:39:55 CEST 2008


Hey,

My dataset has 1 dependent variable(Logloss) and 7 independent dummy
variables(AS,AM,CB,CF,RB,RBR,TS) , it's attached in this email. The problem
is I cant finish Khmaladze test because there's an error "Error in
switch(mode(x), "NULL" = structure(NULL, class = "formula"),  :  invalid
formula" which I really dont know how to fix. My R version is 2.7.2. The
packages loaded are "Quantreq" and "Sparse M", the process is as follows:

 >CPBP<-read.table("CPBP.txt")

> local({pkg <- select.list(sort(.packages(all.available = TRUE)))
+ if(nchar(pkg)) library(pkg, character.only=TRUE)})
Loading required package: SparseM
Package SparseM (0.78) loaded.  To cite, see citation("SparseM")
Package quantreg (4.22) loaded.  To cite, see citation("quantreg")

>  fit<-rqProcess(Logloss~AS+AM+CB+CF+RB+RBR,data=CPBP,taus=-1)

> KhmaladzeTest(fit,nullH="location")
Error in switch(mode(x), "NULL" = structure(NULL, class = "formula"),  :
  invalid formula


I would greatly appreciate if you can help me out, thank you very much!!!!


(See attached file: CPBP.txt)



Best Regards,

Lulu Ren

-----------------------------------------
******************************************************************
This E-mail is confidential. It may also be legally privileged. If
you are not the addressee you may not copy, forward, disclose or
use any part of it. If you have received this message in error,
please delete it and all copies from your system and notify the
sender immediately by return E-mail.

Internet communications cannot be guaranteed to be timely, secure,
error or virus-free. The sender does not accept liability for any
errors or omissions.
******************************************************************
SAVE PAPER - THINK BEFORE YOU PRINT!
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: CPBP.txt
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20081015/47c7829f/attachment.txt>


More information about the R-help mailing list