[R] [Q] a dummy variable used with sapply

2010-08-07 Thread KU
Hello, While learning how to manipulate data with R, I found one example that I could not understand. In the following example, the function definition of "maxcor" has an argument named "i" and I don't understand why. Could someone explain why the maxcor function definition needs to have this

[R] [Q] How to extract cross validation results from e1071's svm model

2010-09-11 Thread GMail (KU)
Dear all, Is it possible to extract cross-validation results from e1071's svm model? For example, the following R code shows the result from the 10 fold cross-validation. model = svm(spam ~ ., data = spam, cross = 10) summary(model) But, I could not figure out how to get to the accuracy values

[R] [Q] Goodness-of-fit test of a logistic regression model using rms package

2010-09-01 Thread GMail (KU)
Hello, I was looking for a way to evaluate the goodness-of-fit of a logistic regression model. After googling, I found that I could use "resid(fit, 'gof')" method implemented in the rms package. However, since I am not used to the "le Cessie-van Houwelingen normal test statistic," I do not know

Re: [R] Using a covariance matrix as input to relaimpo package

2008-12-16 Thread Ku!Rt
By trial and error I have discovered that it works if I don't use the formula interface in combination with a covariance matrix as input. If the covariance matrix has the dependent variable as its left-most variable as the relaimpo documentation suggests, then the relaimpo package will run by sim

[R] Using a covariance matrix as input to relaimpo package

2008-12-15 Thread Ku!Rt
I'm having trouble getting the relaimpo package to use a covariance matrix as input. I'm getting an error message that reads as follows: Error in eval(m$weights, data, parent.frame()) : numeric 'envir' arg not of length one I'm guessing there is something wrong with the structure of my covar

Re: [R] Using a covariance matrix as input to relaimpo package

2008-12-15 Thread Ku!Rt
I just discovered that even with this error message, relaimpo does run and produce output objects that appear fine. It would be nice to know if this error message is serious or not. -- View this message in context: http://www.nabble.com/Using-a-covariance-matrix-as-input-to-relaimpo-package-tp