Learn R Programming

poolABC (version 1.0.0)

organizeSCRM: Organize scrm output

Description

This function is utilized to sort out the scrm output. The order of the populations changes accordingly to the model used (i.e. single or parallel origin). Running this function will re-organize the output produced by scrm, so that the populations are in the same order in both models.

Usage

organizeSCRM(seg_sites, nHap, nPops)

Value

a matrix of segregating sites, similar to seg_sites but with the populations organized so that the order is always the same, regardless of the model used.

Arguments

seg_sites

a matrix of segregating sites as produced by scrm. Each column of the matrix is a different site and each row is a different haplotype.

nHap

an integer representing the total number of haplotypes simulated.

nPops

an integer, representing the total number of populations of the simulated model.