pls icon indicating copy to clipboard operation
pls copied to clipboard

Possible improvement of the `explvar()` function to obtain the explained variance of y

Open AlvaroTorresMartos opened this issue 11 months ago • 1 comments

The explvar() function automatically obtains the explained variance of each component of the PLS model. This function is useful for displaying information in tables or graphs.

To extract the variance explained by Y, a new argument variance = "Y" could be implemented. The default function will use the hypothetical variance = "X" argument to extract the variance explained by X for each component.

The summary() function already calculates the explained variance values of Y per component, but it does not provide this information automatically. Please inform me if it is possible to extract it.

AlvaroTorresMartos avatar Mar 07 '24 12:03 AlvaroTorresMartos

Hi Alvaro,

I wonder if the R2() function satisfactorily covers this request? For printing, R2() can be used directly like MSEP() and RMSEP(), wrapped in plot(R2()) or for export/extraction with R2()$val.

Regards, Kristian

khliland avatar Mar 11 '24 13:03 khliland