Learn R Programming

landsepi (version 1.1.2)

setGenes: Set genes

Description

Updates a LandsepiParams object with parameters associated with resistance genes and pathogen adaptation.

Usage

setGenes(params, dfGenes)

Value

a LandsepiParams object.

Arguments

params

a LandsepiParams object

dfGenes

a data.frame containing gene parameters. It can be defined manually, or, alternatively, with loadGene.

Details

dfGenes is a data.frame of parameters associated with each resistance gene and with the evolution of each corresponding pathogenicity gene. Columns of the dataframe are:

  • geneName: names of resistance genes,

  • target_trait: aggressiveness components (IR, LAT, IP, or PR) targeted by resistance genes,

  • efficiency: resistance gene efficiencies, i.e. the percentage of reduction of the targeted aggressiveness component (IR, 1/LAT, IP and PR),

  • time_to_activ_exp: expected delays to resistance activation (for APRs),

  • time_to_activ_var: variances of the delay to resistance activation (for APRs),

  • mutation_prob: mutation probabilities for pathogenicity genes (each of them corresponding to a resistance gene),

  • Nlevels_aggressiveness: number of adaptation levels related to each resistance gene (i.e. 1 + number of required mutations for a pathogenicity gene to fully adapt to the corresponding resistance gene),

  • fitness_cost: fitness penalties paid by pathogen genotypes fully adapted to the considered resistance genes on host that do not carry these genes,

  • tradeoff_strength: strengths of the trade-off relationships between the level of aggressiveness on hosts that do and do not carry the resistance genes.

The data.frame must be defined as follow (example):

geneNameefficiencytime_to_activ_exptime_to_activ_varmutation_probNlevels_agressivenessfitness_costtradeoff_strengthtarget_trait
MG11001e-0720.51IR
QTL10.5000.0001100.741LAT

See Also

loadGene

Examples

Run this code
if (FALSE) {
simul_params <- createSimulParams()
gene1 <- loadGene(name = "MG 1", type = "majorGene")
gene2 <- loadGene(name = "MG 2", type = "majorGene")
genes <- data.frame(rbind(gene1, gene2), stringsAsFactors = FALSE)
simul_params <- setGenes(simul_params, genes)
simul_params@Genes
}

Run the code above in your browser using DataLab