[R] Loading file to use with qda()

Kwang Kim kim.1406 at osu.edu
Sat Nov 15 15:10:18 CET 2003


z <- qda(train, cl)
save(z, file = "qda.dat")
load("qda.dat")
predict(qda.dat, test)$class

I'm trying to save z where z <-qda(train, cl) and load z for later use in predict(z, test)$class.
I think I successfully saved z by save(z, file = "qda.dat") but when I tried to load by load("qda.dat") and
call predict(qda.dat, test)$class, it gives me error 'object qda.dat is not found'.

Does anybody have an idea?




More information about the R-help mailing list