Differentiation {genepop} | R Documentation |
Tests of genic and genotypic differentiation
Description
Exact conditional contingency-table tests for genic or genotypic differentiation. A single test for all populations, or distinct tests for all pairs of populations, may be computed. See this section of the Genepop executable documentation for more information on the statistical methods.
Usage
test_diff(
inputFile,
genic = TRUE,
pairs = FALSE,
outputFile = "",
settingsFile = "",
dememorization = 10000,
batches = 100,
iterations = 5000,
verbose = interactive()
)
Arguments
inputFile |
The path of the input file, in Genepop format |
genic |
logical: whether to perform genic or genotypic tests |
pairs |
logical: whether to test differentiation between all pairs of ppulation, or to perform a single global test |
outputFile |
character: The path of the output file |
settingsFile |
character: The path of the settings file |
dememorization |
integer: length of dememorization step of Markov chain algorithm |
batches |
integer: Number of batches |
iterations |
integer: Iterations per batch |
verbose |
logical: whether to print some information |
Value
The path of the output file is returned invisibly.
Examples
locinfile <- genepopExample('sample.txt')
test_diff(locinfile,outputFile='sample.txt.GE')
if ( ! interactive()) clean_workdir(otherfiles='sample.txt')