explained_variance: Calculate variance explained for plsr object

Description Usage Arguments Value Examples

View source: R/pls_func.R

Description

Calculates explained variance per component of the original data sets X and Y.

Usage

1

Arguments

plsr_obj

A plsr object

Value

A list containing the elements ExpVarX and ExpVarY, which contain the explained variances for X and Y respectively

Examples

1
2
plsr_object = pls(rating_data,tracking_data,10,10)
explained_variance(plsr_object)

Example output

Be aware that plsr 0.0.1 contains experimental and partly untested code.
Use cautiously.

Attaching package:plsrThe following object is masked frompackage:stats:

    loadings


Permuting...


========
================
========================
================================
========================================
================================================
========================================================
================================================================
========================================================================
================================================================================
Done!
Bootstrapping...
Done!
Warning messages:
1: In pls(rating_data, tracking_data, 10, 10) :
  Bootstrapping functionality is still untested! No guarantee for correctness! Use with extra care.
2: In pls(rating_data, tracking_data, 10, 10) :
  Some p-values are not stable under this precision.
 Try to increase the number of permutation steps (n_perm).
$ExpVarX
          [,1]      [,2]      [,3]      [,4]      [,5]      [,6] [,7]
[1,] 0.4920539 0.6785452 0.8424196 0.8931537 0.9536591 0.9878328    1

$ExpVarY
         [,1]      [,2]     [,3]      [,4]      [,5]      [,6]      [,7]
[1,] 0.170713 0.4927914 0.692218 0.7401846 0.7817284 0.8000143 0.8304473

plsr documentation built on May 1, 2019, 11:28 p.m.