[R-sig-eco] Sliding window mantel test (vegan)

Gerald Cobian gmcobian at hawaii.edu
Wed Nov 2 02:53:49 CET 2016


Dear list members, 

I performed a mantel test on data from an elevation gradient with a distance of about 14 km. Additionally, I did another mantel test where elevation was held constant, but the distance was only for about 5 km. I got a significant mantel value for the elevation and a flat value for distance. However, since the distances are not comparable, I want to do a sliding window regression along the elevation gradient in order to compare the distance with the elevation. 

I was able to split the elevation gradient into different segments and graph a regression line for each. However, now I want to calculate mantel on each of those to make them comparable, but when subsetted my data, I had to make the other values NAs, and my matrices are now NAs swiss cheese. 

My question: Is there a way to calculate mantel with all the NAs? I’ve tried with no success. I cannot change the values to zeros because my y-axis is community dissimilarity, and a value of zero means the communities are exactly the same. 

I hope my situation and question are clear enough. 

Best, 
Gerry

______________________________
Gerry Cobian
PhD Candidate
Amend Lab <http://www.amendlab.com/>
Personal Site <http://www2.hawaii.edu/~gmcobian/>

University of Hawaii
Department of Botany, 101 St. John
3190 Maile Way 
Honolulu, HI 96822

gmcobian at hawaii.edu


	[[alternative HTML version deleted]]



More information about the R-sig-ecology mailing list