Murdoch University Research Repository

Welcome to the Murdoch University Research Repository

The Murdoch University Research Repository is an open access digital collection of research
created by Murdoch University staff, researchers and postgraduate students.

Learn more

Comspat: an R package to analyze within‐community spatial organization using species combinations

Tsakalos, J.L., Chelli, S., Campetella, G., Canullo, R., Simonetti, E. and Bartha, S. (2022) Comspat: an R package to analyze within‐community spatial organization using species combinations. Ecography .

Free to read:
*No subscription required


The diversity of species combinations observable in sampling units reflects a species' uneven distribution and preference for specific abiotic and biotic conditions – a phenomenon most commonly expressed in terms of ecological assembly rules of plant communities and other sessile organisms (e.g. subtidal algae, invertebrates and coral reefs). We present comspat, a new R package that uses grid or transect data sets to measure the number of realized (observed) species combinations (NRC) and the Shannon diversity of realized species combinations (compositional diversity; CD) as a function of spatial scale. NRC and CD represent two measures from a model family developed by Pál Juhász-Nagy based on information theory. Classical Shannon diversity measures biodiversity based on the number and relative abundance of species, whereas the specific version of Shannon diversity presented here characterizes biodiversity and provides information on species coexistence relationships; both measures operate at fine-scale within the sampling unit or within the community. comspat offers two commonly applied null models, complete spatial randomness and random shift, to disentangle the textural, intraspecific and interspecific effects on the observed spatial patterns. Combined, these models assist users in detecting and interpreting spatial associations and inferring assembly mechanisms. Our open-sourced package provides a vignette that describes the method and reproduces the figures from this paper to help users contextualize and apply functions to their data.

Item Type: Journal Article
Murdoch Affiliation(s): Harry Butler Institute
Publisher: Blackwell Publishing Inc.
Copyright: © 2022 The Authors.
Item Control Page Item Control Page


Downloads per month over past year