hSDM R package

hSDM is an R package for estimating parameters of hierarchical Bayesian species distribution models. Such models allows interpreting the observations (occurrence and abundance of a species) as a result of several hierarchical processes including ecological processes (habitat suitability, spatial dependence and anthropogenic disturbance) and observation processes (species detectability). Hierarchical species distribution models are essential for accurately characterizing the environmental response of species, predicting their probability of occurrence, and assessing uncertainty in the model results.

Stable version

The last stable version of the hSDM R package is officially available for several operating systems (Unix, Windows and Mac OSX)  on the Comprehensive R Archive Network (CRAN).

Manual and vignette

Package manual and vignette are available here:

Source code

The source code is available through git on the Sourceforge platform (read only access for the moment):

git clone git://git.code.sf.net/p/hsdm/code hsdm-code

Tutorials on internet

Scientific papers using the hSDM R package

Domisch, S.; Wilson, A. M. & Jetz, W. 2015. Model-based integration of observed and expert-based information for assessing the geographic and environmental distribution of freshwater species. Ecography. http://dx.doi.org/10.1111/ecog.01925

Scientific papers citing the hSDM R package

Bird, T. J., Bates, A. E., Lefcheck, J. S., Hill, N. A., Thomson, R. J., Edgar, G. J., … & Pecl, G. T. (2014). Statistical solutions for error and bias in global citizen science datasets. Biological Conservation. 173: 144-154. http://dx.doi.org/10.1016/j.biocon.2013.07.037

Lee, D. (2013). CARBayes: An R package for Bayesian spatial modeling with conditional autoregressive priors. Journal of Statistical Software. 55(13): 1-24. http://dx.doi.org/10.18637/jss.v055.i13

Mazerolle, M. J. (2015). Estimating Detectability and Biological Parameters of Interest with the Use of the R Environment. Journal of Herpetology. http://dx.doi.org/10.1670/14-075

Thuiller, W. (2014). Editorial commentary on “BIOMOD – optimizing predictions of species distributions and projecting potential future shifts under global change”. Global Change Biology. 20: 3591-3592. http://dx.doi.org/10.1111/gcb.12728

Methodological related publications

Gelfand A. E., Silander J. A., Wu S. S., Latimer A., Lewis P. O., Rebelo A. G. and Holder M. 2006. Explaining species distribution patterns through hierarchical modeling. Bayesian Analysis. 1(1): 41-92. pdf

Latimer A. M., Wu S. S., Gelfand A. E. and Silander J. A. 2006. Building statistical models to analyze species distributions. Ecological Applications. 16(1): 33-50. pdf

MacKenzie D. I., Nichols J. D., Lachman G. B., Droege S., Royle J. A. and Langtimm C. A. 2002. Estimating site occupancy rates when detection probabilities are less than one. Ecology. 83: 2248-2255. pdf

Royle, J. A. 2004. N-Mixture Models for Estimating Population Size from Spatially Replicated Counts. Biometrics. 60: 108-115. pdf


Ghislain Vieilledent
Campus de Baillarguet
TA C-105/D
34398 Montpellier cedex 5

Skype: ghislain.vieilledent
Email: ghislain(dot)vieilledent(at)cirad(dot)fr
WWW: http://ghislain.vieilledent.free.fr