no applicable method for 'predict' applied to an object of class "randomForest"

I am loading a randomforest model

 my_model <- readRDS(paste0("/path/to/model/",gene_name, ".RDS"))

then I send a new data for prediction

 Exp_real = predict(my_model, newdata = gene_real)

but it shows this error:
no applicable method for 'predict' applied to an object of class "randomForest"

do you know how can I fix this error:
I also loaded needed packages.
thanks in advance

I can't think of anyway for that to happen except not having the randomForest package loaded. Please show the output of running

search()

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.