README.md

traitsPopSim

v0.9-1; 2020-11-03 DOI

R package for simulating traits collected in populations, with autocorrelation by individual and by population. For full study, see:

Desmond SC, Garner M, Flannery S, Whittemore AT, Hipp AL. 2021. Leaf shape and size variation in bur oaks: an empirical study and simulation of sampling strategies. American Journal of Botany. doi:10.1002/ajb2.1705.

Before installing, install dependencies:

install.packages('agricolae')
install.packages('egg')
install.packages('magrittr')
install.packages('mvtnorm')
install.packages('reshape')

Then, install from GitHub using devtools. If you are a Windows user, you will also need Rtools (if you are using R > v4.0, follow the directions at https://cran.r-project.org/bin/windows/Rtools/, and be patient).

install.packages('devtools')
library('devtools')
install_github('andrew-hipp/traitsPopSim', ref = 'main')

For a worked example, see https://github.com/andrew-hipp/oak-morph-2020, released under DOI.

Note that you may get a "Lazy load database corrupt" error if you run the package right after installation. If so, don't worry! Close R, open again, bring the package back in using library(traitsPopSim) and it should work fine. I've installed the package successfully from GitHub under Windows 10 (running R 4.0.2, 'Taking Off Again'; and R 3.6.2, 'Dark and Stormy Night') and Ubuntu 16.04 (running R 4.0.3, 'Bunny-Wunnies Freak Out').



andrew-hipp/traitsPopSim documentation built on Aug. 20, 2021, 6:28 p.m.