Oh. I understand now. There is nothing wrong with the logic. It is the
syntax.
library(AppliedPredictiveModeling)
*Warning message:*
*package ‘AppliedPredictiveModeling’ was built under R version 3.1.1 *
set.seed(3433)
data(AlzheimerDisease)
adData = data.frame(diagnosis,predictors)
Thanks Max and Dennis. Based on the syntax change I got the result for the
PCA part also.
training2 - training[,grepl(^IL,names(training))]
preProc - preProcess(training2,method=pca,thresh=0.8)
test2 - testing[,grepl(^IL,names(testing))]
trainpca - predict(preProc, training2)
testpca -
Hi Dennis,
Why is there that warning ? I think my syntax is
right. Isn't it not? So the warning can be ignored ?
Thanks,
Mohan
On Wed, Sep 17, 2014 at 9:48 PM, Dennis Murphy djmu...@gmail.com wrote:
No reproducible example (i.e., no data) supplied, but the following
You have not shown all of your code and it is difficult to diagnose the
issue.
I assume that you are using the data from:
library(AppliedPredictiveModeling)
data(AlzheimerDisease)
If so, there is example code to analyze these data in that package. See
?scriptLocation.
We have no idea how
4 matches
Mail list logo