A two-block partial least squares (PLS) analysis is useful when one
wishes to quantify the degree of association (covariance) between two
sets of variables. A PLS analysis has characteristics similar to that of
linear regression in that the result of an analysis is linear
combinations of variables. Likewise, however, PLS maintains some
characteristics similar to ordination methods such as PCA, in that the
result is mutually orthogonal axes derived from a covariance matrix. The
difference is that, the axes generated from a PLS analysis describe
covariance between the two input data sets, rather than variance, and
are derived from an inter-block covariance matrix. In
geomorph, can perform a PLS analysis between sets of
Procrustes variables (or other variables) using the
two.b.pls function.
two.b.pls()
Below is example code using the “plethShapeFood” dataset, included by
default with geomorph.
PLS <- two.b.pls(gpa$coords, food, iter = 999, print.progress = F)
summary(PLS)
##
## Call:
## two.b.pls(A1 = gpa$coords, A2 = food, iter = 999, print.progress = F)
##
##
##
## r-PLS: 0.759
##
## Effect Size (Z): 3.8842
##
## P-value: 0.001
##
## Based on 1000 random permutations
plot(PLS)
Results of multiple two-block comparisons made with
two.b.pls can be compared using the compare.pls function in geomorph. Note that
this function is also used to compare results of the
integration.test and phylo.integration
functions which are addressed in other tutorials.
PLS1 <- two.b.pls(gpa$coords[,,1:30], food[1:30,], iter = 999, print.progress = F)
PLS2 <- two.b.pls(gpa$coords[,,31:69], food[31:69,], iter = 999, print.progress = F)
compare <- compare.pls(PLS1,PLS2)
summary(compare)
##
## Effect sizes
##
## PLS1 PLS2
## -0.6627612 1.9864493
##
## Effect sizes for pairwise differences in PLS effect size
##
## PLS1 PLS2
## PLS1 0.000000 2.037695
## PLS2 2.037695 0.000000
##
## P-values
##
## PLS1 PLS2
## PLS1 1.00000000 0.04158041
## PLS2 0.04158041 1.00000000
To perform a similar analysis with a single function, see the tutorial for integration.test.
two.b.pls Output
This function returns an object of class “pls” that contains the following values, each of which can be accessed with the $ operator.
Important Note! If one wishes to incorporate a phylogeny in a PLS analysis, please see the tutorial for the phylo.integration function.