fillPipeline: fillPipeline function

Description Usage Arguments Details Value Examples

View source: R/InitializationFunctions.R

Description

function to create initial records at the start of a simulation

Usage

1
fillPipeline(founders, bsp = NULL, SP)

Arguments

founders

Pop-class object of the founders of the breeding program

bsp

A list of product pipeline parameters. See runBreedingScheme for details

Details

This is a structure for a records object that will be used to simulate breeding schemes

Value

A records object. A list of lists containing nStages+1 lists. The first list contains one Pop-class of progeny per year of the scheme. The remaining lists contain one matrix per year that has individual id, mother, father, stage, phenotypes, and error variances. The individuals have been phenotyped using setPheno. The matrix may contain a mix of experimental and check phenotypes with different levels of replication

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
bsp <- specifyPipeline()
bsp <- specifyPopulation(bsp)
nF1 <- bsp$nCrosses * bsp$nProgeny
founderHap <- runMacs(nInd=nF1, nChr=bsp$nChr, segSites=bsp$segSites)
SP <- SimParam$new(founderHap)
SP$addTraitA(nQtlPerChr=bsp$nQTL, var=bsp$genVar)
SP$addSnpChip(bsp$nSNP)
founders <- newPop(founderHap, simParam=SP)
bsp <- c(bsp, checks=list(NULL))
records <- fillPipeline(founders, bsp, SP)

jeanlucj/AlfSimHlpR documentation built on Nov. 7, 2021, 5:10 p.m.