multi.mantel: Multiple matrix regression (partial Mantel test)

View source: R/multi.mantel.R

multi.mantelR Documentation

Multiple matrix regression (partial Mantel test)

Description

This function conducting a multiple matrix regression (partial Mantel test) and uses Mantel (1967) permutations to test the significance of the model and individual coefficients. It also returns the residual and predicted matrices.

Usage

multi.mantel(Y, X, nperm=1000)

Arguments

Y

single "dependent" square matrix. Can be either a symmetric matrix of class "matrix" or a distance matrix of class "dist".

X

a single independent matrix or multiple independent matrices in a list. As with Y can be a object of class "matrix" or class "dist", or a list of such objects.

nperm

number of Mantel permutations to be used to compute a P-value of the test.

Details

Printing the object to screen will result in a summary of the analysis similar to summary.lm, but with p-values derived from Mantel permutations.

Methods residuals and fitted can be used to return residual and fitted matrices, respectively.

Value

An object of class "multi.mantel" consisting of the following elements:

r.squared

multiple R-squared.

coefficients

model coefficients, including intercept.

tstatistic

t-statistics for model coefficients.

fstatistic

F-statistic for the overall model.

probt

vector of probabilities, based on permutations, for tstatistic.

probF

probability of F, based on Mantel permutations.

residuals

matrix of residuals.

predicted

matrix of predicted values.

nperm

the number of permutations used.

Author(s)

Liam Revell liam.revell@umb.edu

References

Mantel, N. (1967) The detection of disease clustering and a generalized regression approach. Cancer Research, 27, 209-220.

Revell, L. J. (2024) phytools 2.0: an updated R ecosystem for phylogenetic comparative methods (and other things). PeerJ, 12, e16505.


phytools documentation built on June 22, 2024, 10:39 a.m.