mating: Mating function

View source: R/glads_funcs.R

matingR Documentation

Mating function

Description

A function to select the mating pairs

Usage

mating(z, G)

Arguments

z

A data.frame with the sex and fitness value of each individual in the population.

G

An object of class "struct" with the genetic structure of each individual in the population.

Details

The function is used internally in the function newborns() in order to select the mating pairs. This function returns a three-dimensional array. Rows represent individuals and columns the different loci. Each element of the array is an integer defining the copy of a given allele at a given locus. The third dimension of the array has two layers representing a pair of homologous chromosomes.

Value

A list of two objects of class "struct". The first element represents the genetic structure of reproductive females and the second element the genetic structure of reproductive males in the population.

See Also

newborns evolve


eriqande/glads documentation built on Jan. 26, 2024, 9:25 p.m.