Models Spatially Continuous and Discrete Population Genetic Structure

A method for modeling genetic data as a combination of discrete layers, within each of which relatedness may decay continuously with geographic distance. This package contains code for running analyses (which are implemented in the modeling language 'rstan') and visualizing and interpreting output. See the paper for more details on the model and its utility.


conStruct 1.0.3

Major changes

  • added ... to conStruct and x.validation so additional arguments can be passed to rstan::sampling

Bug fixes

  • fixed aliasing due to inefficient deep copy in stan model
  • removed duplicated vignettes displayed on CRAN page

conStruct 1.0.2

Bug fixes

  • updated Makevars and to be in compliance with CRAN policy

conStruct 1.0.1

Major changes

  • following move to C++14 by Stan
  • structure2conStruct now works for multiple STRUCTURE file formats

Bug fixes

  • users can now specify their own custom plotting colors in make.all.the.plots

conStruct 1.0.0

Major changes

  • stan model blocks are now compiled at package installation instead of at a call to conStruct or x.validation.
  • x.validation is now parallelizable
  • new model-comparison vignette (see vignette("model-comparison",package="conStruct"))
  • alphaD parameter is now rescaled to reflect non-normalized geographic distances
  • compare.two.runs function added

Bug fixes

  • Removed large files in git history on repo


Beta release

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.


1.0.4 by Gideon Bradburd, a year ago

Browse source code at

Authors: Gideon Bradburd [aut, cre]

Documentation:   PDF Manual  

GPL-3 license

Imports rstan, rstantools, caroline, gtools, foreach, parallel, doParallel

Depends on Rcpp, methods

Suggests knitr, rmarkdown, maps

Linking to StanHeaders, rstan, BH, Rcpp, RcppEigen

System requirements: GNU make

See at CRAN