sim.autoCross function

Simulate dominant markers for an autopolyploid cross for all parental types

Simulate dominant markers for an autopolyploid cross for all parental types

Simulates dominant markers from an autopolyploid cross given the ploidy level and/or expected segregation ratios and the proportions in each dosage marker class. This is a wrapper to sim.autoMarkers to generate markers for 10 , 01 and 11 parents

sim.autoCross(ploidy.level, prop.par.type = structure(c(0.4, 0.4, 0.2), names = c("p10", "p01", "p11")), n.markers = 500, n.individuals = 200, dose.proportion, true.seg.ratios, no.dosage.classes, marker.names = paste("M", 1:n.markers, sep = "."), individual.names = paste("X", 1:n.individuals, sep = "."), parent.names = c("P.1", "P.2"), seed)

Arguments

  • ploidy.level: the number of homologous chromosomes, either as numeric (single value) or as a character string containing type tetraploid, hexaploid, octoploid, ...
  • prop.par.type: the proportion of markers generated from each parental type '10', '01' and '11'. Note that the exact number will be randomly generated from the multinomial distribution (Default: c(0.4,0.4,0.2))
  • n.markers: number of markers (Default: 500)
  • n.individuals: number of individuals in the cross (Default: 200)
  • dose.proportion: the proportion of markers to be simulated in each dosage class. Note that the exact number will be randomly generated from the multinomial distribution NB: If a vector is supplied the dose.proportion is same for each parental type otherwise as list with components p01 , p10 and p11
  • true.seg.ratios: numeric vector containing segregation proportion to be supplied if you wish to overide automatic calculations using ploidy.level
  • no.dosage.classes: numeric vector containing the number of dosage classes
  • marker.names: labels for markers (Default: M.1 ... M.n.markers)
  • individual.names: labels for offspring (Default: ... X.j ... )
  • parent.names: numeric vector of length 2 containing columns of marker matrix containing parental markers (Default: first 2 columns)
  • seed: integer used to set seed for random number generator (RNG) which (if set) may be used to reproduce results

Returns

Returns an object of class simAutoCross containing - markers: matrix of 0,1 dominant markers with individuals as cols and rows as markers

  • true.dosage: true doses for each marker

  • name.true.dose: names of true doses for each marker

  • p10: object of class simAutoMarkers for parental type 10

  • p01: object of class simAutoMarkers for parental type 01

  • p11: object of class simAutoMarkers for parental type 11

  • ploidy.level: the number of homologous chromosomes as numeric (single value)

  • prop.par.type: proportion of markers for each parental type p01 , p10 and p11

  • n.markers: number of markers (Default: 500)

  • n.individuals: number of individuals in the cross (Default: 200)

  • dose.proportion: proportion in each dose -- if numeric vector is the same for p01 , p10 and p11 else a list with components p01 , p10 and p11

  • no.dosage.classes: number in each dosage class

  • no.parType: number in each parental type

  • time.generated: time/date when data set generated

  • seed: seed for random number generator seed which could be used to reproduce results (I hope)

  • call: matches arguments when function called

Author(s)

Peter Baker p.baker1@uq.edu.au

Note

All parameters except the proportions of marker dosage types can be left at the default. If only one value is set, then individual list components will be assumed to be equal. The marker matrix is prepended with parental marker alleles. An alternative is to simply create each group using sim.automarkers and cbind them.

See Also

simAutoCross,simAutoMarkers, sim.autoMarkers

Examples

p1 <- sim.autoCross(4, dose.proportion=c(0.7,0.3), n.markers=20, n.indiv=10) print(p1) p2 <- sim.autoCross(4, dose.proportion=list(p01=c(0.7,0.3),p10=c(0.7,0.3),p11=c(0.6,0.2,0.2))) print(p2)
  • Maintainer: Peter Baker
  • License: GPL-3
  • Last published: 2018-03-22

Useful links