08.04.2015 Views

The ade4 Package - NexTag Supports Open Source Initiatives

The ade4 Package - NexTag Supports Open Source Initiatives

The ade4 Package - NexTag Supports Open Source Initiatives

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

108 genet<br />

Description<br />

<strong>The</strong>re are multiple formats of genetic data. <strong>The</strong> functions of <strong>ade4</strong> associated genetic data use the<br />

class genet. An object of the class genet is a list containing at least one data frame whose<br />

lines are groups of individuals (populations) and columns alleles forming blocks associated with<br />

the locus. <strong>The</strong>y contain allelic frequencies expressed as a percentage.<br />

<strong>The</strong> function char2genet ensures the reading of tables crossing diploid individuals arranged by<br />

groups (populations) and polymorphic loci. Data frames containing only strings of characters are<br />

transformed in tables of allelic frequencies of the class genet. In entry a row is an individual, a<br />

variable is a locus and a value is a string of characters, for example ’ 012028 ’ for a heterozygote<br />

carrying alleles 012 and 028, ’ 020020 ’ for a homozygote carrying two alleles 020 and ’ 000000 ’<br />

for a not classified locus (missing data).<br />

<strong>The</strong> function count2genet reads data frames containing allelic countings by populations and<br />

allelic forms classified by locus.<br />

<strong>The</strong> function freq2genet reads data frames containing allelic frequencies by populations and<br />

allelic forms classified by locus.<br />

In these two cases, use as names of variables of strings of characters xx.yyy where xx are the<br />

names of locus and yyy a name of allelic forms in this locus. <strong>The</strong> analyses on this kind of data<br />

having to use compact labels, these functions classify the names of the populations, the names of<br />

the loci and the names of the allelic forms in vectors and re-code in a simple way starting with P for<br />

population, L for locus and 1,. . . , m for the alleles.<br />

Usage<br />

char2genet(X, pop, complete)<br />

count2genet(PopAllCount)<br />

freq2genet(PopAllFreq)<br />

Arguments<br />

X<br />

pop<br />

complete<br />

PopAllCount<br />

PopAllFreq<br />

a data frame of strings of characters (individuals in row, locus in variables), the<br />

value coded ’000000’ or two alleles of 6 characters<br />

a factor with the same number of rows than df classifying the individuals by<br />

population<br />

a logical value indicating a complete issue or not, by default FALSE<br />

a data frame containing integers: the occurrences of each allelic form (column)<br />

in each population (row)<br />

a data frame containing values between 0 and 1: the frequencies of each allelic<br />

form (column) in each population (row)<br />

Details<br />

As a lot of formats for genetic data are published in literature, a list of class genet contains at<br />

least a table of allellic frequencies and an attribut loc.blocks. <strong>The</strong> populations (row) and the<br />

variables (column) are classified by alphabetic order. In the component comp, each individual per<br />

locus of m alleles is re-coded by a vector of length m: for hererozygicy 0,. . . ,1,. . . ,1,. . . ,0 and<br />

homozygocy 0,. . . ,2,0.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!