knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

peas

The purpose of this R package is to predict offspring distributions in genetic crosses. The package contains functions for defining systems of Mendelian inheritance (defined broadly), and making predictions about the distribution of offspring genotypes and phenotypes in genetic crosses. The package can handle multiple linkage groups with autosomal, sex-chromosomal or uniparental inheritance, with arbitrary numbers of loci and alleles per locus. Multiple traits can be freely defined, potentially involving pleiotropy, polygeny and epistasis.

Example

Here is a simple example for how one can define a genetic system along with a trait:

library(peas)
MendelsPeas <- newGenopheno(alleleNames = list(c('Y', 'y')))
MendelsPeas <- setPhenotypes(MendelsPeas, 'colour', 'Y_', 'yellow')
MendelsPeas <- setPhenotypes(MendelsPeas, 'colour', 'yy', 'green')
MendelsPeas

Once defined, it is easy to predict offspring genotype and phenotype distributions in crosses:

predictCross(MendelsPeas, 'Yy', 'Yy')

A detailed description of the package with more examples can be found in the package vignette (after installing the package, call browseVignettes("peas")).

Installation

To install the peas package, you can run the following two lines of code in R:

install.packages("devtools")
devtools::install_github("JanEngelstaedter/peas", build_opts = c("--no-resave-data", "--no-manual"))


JanEngelstaedter/peas documentation built on May 5, 2019, 1:33 a.m.