PlotLoadings for rcc


I’ve used the plotLoadings function with the output of spls and it worked well. When I try to use the same function with the results of rcc I get this error:

Error in UseMethod(“selectVar”) :
no applicable method for ‘selectVar’ applied to an object of class “rcc”

What can be done in this case?
Thank you for your help and all the magnificent work you’re doing with mixOmics.

hi @Lona

We have not implemented plotLoading() for rcc as it is not designed to do variable selection (also, the actual interpretation of the loadings in rcc are a bit different from PLS). The closest equivalent would be spls(mode = 'canonical'). This is one of the main limitation of rcc. What you can do is use plotVar() with a cutoff value to visualise the most important variables in rCCA.


Hello Kim-Anh,
thanks very much for your feedback!