PrepareData | R Documentation |
Prepare a structure file (or similar data table) for differential introgression analysis using gghybrid.
PrepareData(Data, numprecol, missingval, onerow, numinds, S0.id, S1.id)
Data |
Character string defining the structure or data table to read in. |
numprecol |
Numeric, the number of columns preceding the genetic data. |
missingval |
Numeric or character, The value for indicating missing data. |
onerow |
Numeric, (0 or 1). Whether or not there is a single row per individual. Currently, HybridFindR only supports 0. |
numinds |
Numeric, the number of individuals in your data file. |
S0.id |
Character, the label for the S0 parental population. |
S1.id |
Character, the label for the S1 parental population. |
Returns a genotype table based on the number of copies of the S1 allele in each individual at each marker.
Bailey R. (2020) gghybrid: R package for evolutionary analysis of hybrids and hybrid zones.10.5281/zenodo.3676499
## Not run:
Data <- PrepareData('mystructurefile.csv', numprecol = 2, missingval = 'NA',
onerow = 0, numinds = 73, S0.id = 'P', S1.id = 'K')
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.