genepop_rubias: Convert Genepop to rubias format.

View source: R/genepop_rubias.R

genepop_rubiasR Documentation

Convert Genepop to rubias format.

Description

Function to convert Genepop to rubias format for individual assignment and mixture analyses.

Usage

genepop_rubias(genepop, sampletype, repunits, path)

Arguments

genepop

the genepop data to be manipulated. This is read in as a complete file path. This will the standard genepop format with a the first n+1 rows corresponding the the n loci names, or a single comma deliminated row of loci names followed by the locus data. Populations are separated by "Pop". Each individual ID is linked to the locus data by " , " (space,space space) and is read in as as a single row (character).

sampletype

Specifies whether your rubias input file is a reference (baseline) or mixture file. Can only be one of "reference" or "mixture"

repunits

A vector from the workspace that specifies which individuals are assigned which reporting unit. The length of this vector should be equal to the number of individuals in the original genepop file. Can also use genepop_aggregate to generate this vector.

path

file path to directory where the rubias input file will be saved.


rystanley/genepopedit documentation built on June 27, 2023, 11:33 p.m.