Contingency-test {genepop} | R Documentation |
Exact test on a single contingency table
Description
Performs an exact conditional contingency-table test. There are many other ways of doing this in R but this function replicates the functionality of earlier genepop code analysing a contingency table provided in a file with ad hoc format. See this section of the Genepop executable documentation for more information on the statistical methods.
Usage
struc(
inputFile,
settingsFile = "",
dememorization = 10000,
batches = 100,
iterations = 5000,
verbose = interactive()
)
Arguments
inputFile |
character: The path of the input file. This file should be in an ad hoc format |
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('structest.txt')
struc(locinfile)
if ( ! interactive()) clean_workdir(otherfiles='structest.txt')
[Package genepop version 1.2.2 Index]