Regressions to Separate Phylogenetic Attraction and Repulsion
Fit regressions on species abundance or presence/absence across communities and calculate phylogenetic correlations
sppregs(samp, env, tree=NULL, fam="gaussian") sppregs.plot(sppreg, rows=c(1,3), cex.mag=1, x.label="phylogenetic correlations", y.label=c("occurrence correlations w/ env", "occurrence correlations wo/ env", "change in correlations"))
samp |
community data matrix, species as columns, communities as rows |
env |
environmental data matrix |
tree |
phylo tree object or a phylogenetic covariance matrix |
fam |
with |
sppreg |
object from function |
rows |
|
cex.mag |
value for |
x.label |
x axis labels |
y.label |
y axis labels |
For each species in samp
, the function fits regressions of species presence/absence or abundances
on the environmental variables supplied in env
; and calculates the (n^2-n)/2
pairwise species correlations
between the residuals of these fits and pairwise species phylogenetic correlations. The residuals can be
thought of as the presence/absence of species across sites/communities after accounting for how species respond
to environmental variation across sites. Each set of coefficients can be tested for phylogenetic signal with, for example,
the function phylosignal
.
The function sppregs.plot
produces a set of three plots of the correlations of pairwise species phylogenetic correlations versus:
the observed pairwise correlations of species across communities, the residual correlations, and the pairwise differences between (i.e., the
change in species co-occurrence once the environmental variables are taken into account). The significance of these correlations can be tested
via permutation with the function phylostruct
.
family |
the regression error distribution |
residuals |
the residuals from each species regression |
coefficients |
the estimated coefficients from each species regression |
std.errors |
the standard errors of the coefficients |
correlations |
correlations of pairwise species phylogenetic correlations between: the observed pairwise correlations of species across communities, the residual correlations, and the pairwise differences between the two |
cors.pa |
the observed pairwise correlations of species across communities |
cors.resid |
the residual pairwise correlations of species across communities |
cors.phylo |
the phylogenetic pairwise correlations among species |
The function requires the library brglm
to perform logistic regressions
Matthew Helmus mrhelmus@gmail.com
Helmus M.R., Savage K., Diebel M.W., Maxted J.T. & Ives A.R. (2007) Separating the determinants of phylogenetic community structure. Ecology Letters, 10, 917-925
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.