rsvsim.immunity module¶
Defines classes and methods for calculating immunity
-
class
rsvsim.immunity.
genotype
(genotype, days, label=None, n_imports=1, rescale=True)[source]¶ Bases:
sciris.sc_utils.prettyobj
Add a new genotype to the sim
- Parameters
genotype (str/dict) – name of genotype, or dictionary of parameters specifying information about the genotype
days (int/list) – day(s) on which new genotype is introduced
label (str) – if genotype is supplied as a dict, the name of the genotype
n_imports (int) – the number of imports of the genotype to be added
rescale (bool) – whether the number of imports should be rescaled with the population
Example:
groupA = cv.genotype('groupA', days=10) # Make genotype groupA active from day 10 groupB = cv.genotype('groupB', days=15) # Make genotype groupB active from day 15 my_geno = cv.genotype(genotype={'rel_beta': 2.5}, label='My genotype', days=20) sim = cv.Sim(genotype=[groupA, groupB, my_geno]).run() # Add them all to the sim