h$@:φ      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                               (c) 2021 Alexander E. ZarebskiMIT,Alexander E. Zarebski unstableghcNone8 epi-sim!A type to represent a population.epi-sim2A type to represent a single person in a group of epi-sim2A type to hold an integer which is unique to each .epi-simClass of types that can represent populations in an epidemic simulation. epi-simA list of persons as a people epi-sim3Predicate for whether a person is one of the people epi-simPredicate for whether two sets of people have any members in common.epi-sim*Predicate for whether there are any peopleepi-simThe number of peopleepi-sim!Add a person to a group of peopleepi-sim&Remove a person from a group of peopleepi-sim!A bytestring builder for a person   None#$8"epi-simType containing values at times. The times are increasing as required by asTimed.$epi-simAn interval of time(epi-sim,Duration of time between two absolute times.*epi-simA type that has an absolute time associated with it and can be treated as having a temporal ordering. 4a = AbsoluteTime 1 b = AbsoluteTime 2 a `isBefore` b.epi-simAbsolute time.0epi-sim/The duration of time between two absolute times-timeDelta (AbsoluteTime 1) (AbsoluteTime 2.5) TimeDelta 1.51epi-simThe time after a given delay/timeAfterDelta (AbsoluteTime 1) (TimeDelta 2.5)AbsoluteTime 3.52epi-sim Construct a $ from the end points.3epi-sim Construct a $& from the start time and the duration.4epi-sim Check if an . sits within a $.5epi-simConstruct a list of consecutive intervals divided by the given absolute times.6epi-sim#Construct a timed list if possible.7epi-simPredicate to check if a list of orderable objects is in ascending order.8epi-sim:Evaluate the timed object treating it as a cadlag function9epi-simEvaluate the timed object treating it as a direct delta function:epi-sim:Check if there exists a pair with a particular time index.;epi-simReturn the value of the next time if possible or an exact match if it exists.<epi-simReturn a list of the (finite) absolute times that the step function changes value.let demoMaybeTimed = asTimed [(AbsoluteTime 1,2),(AbsoluteTime 1.5,1)]liftM allTimes demoMaybeTimed(Just [AbsoluteTime 1.0,AbsoluteTime 1.5]=epi-simThe values that the timed variable takes. NOTE that it is safe to use fromJust here because <> only returns times for which there is a cadlag value anyway.=(Just tx) = asTimed [(AbsoluteTime 1,2),(AbsoluteTime 1.5,1)] allValues tx[2,1]>epi-simLook at both of the timed objects and, if possible, return the time that the first one changes along with the value it changes to.(Just tA) = asTimed [(AbsoluteTime 1, (1.1 :: Double)), (AbsoluteTime 3, 2.3)]2(Just tB) = asTimed [(AbsoluteTime 2, (1 :: Int))]'maybeNextTimed tA tB (AbsoluteTime 0.5) Just (AbsoluteTime 1.0,Left 1.1)'maybeNextTimed tA tB (AbsoluteTime 1.5)Just (AbsoluteTime 2.0,Right 1)'maybeNextTimed tA tB (AbsoluteTime 3.5)Nothing0epi-simstartepi-simfinish6epi-sim"list of ascending times and values"#$%&'()*+,-./0123456789:;<=>./()$%&'"#*+,-<=5689:47>;1023(c) 2021 Alexander E. ZarebskiMIT,Alexander E. Zarebski unstableghcNoneWepi-sim A probabilityXepi-sim!The rate at which an event occursYepi-simClass of types that can be considered parameterisations of a epidemic model.Zepi-simThe basic reproduction number.NOTE that this is not the  effective reproduction number the population is included in case there is structure other than immunity that needs to be accounted for.[epi-sim3The total event rate at a particular point in time.\epi-sim:The probability that an event will result in an infection.]epi-simThe  unnormalised) distribution across the possible events.WXY]\[ZY]\[ZXWNone #$8 ^epi-simThe whole transmission tree including the unobserved leaves. Lineages that are still extant are modelled as shoots and contain a % as their data rather than an event.bepi-sim>Events that can occur in an epidemic with their absolute time.cepi-sim!absolute time; infector; infecteegepi-simepidemic went extincthepi-sim(the simulation reached the stopping timeoepi-sim9Predicate for the event being an individual sample event.pepi-simPredicate for whether an  EpidemicEvent is one of the terminal events of extinction or the stopping time having been reached.qepi-simThe events that occurred as a result of the existance of the given person.repi-simIf possible return an ^ describing the sorted list of b.sepi-simEpidemic Events are ordered based on which occurred first. Since g and h events are there as placeholders they are placed as the end of the order.qepi-simordered epidemic eventsrepi-simordered epidemic events^_`abcdefhgikjlmnopqrbcdefhgmnljki^_`arpoqNone'(a |epi-simCheck if a simulation should be terminated and if it should be terminated, then compute a summary explaining why. The first function is used to determine whether the population has entered a state which requires the simulation to terminate early and the second can be use to write a summary of the events that led to the termination.epi-simEither there is a valid simulation state which contains a sequence of epidemic events along with the time and population or, if the simulation has terminated early there is another value to indicate that along with a value which can be used to indicate why the simulation was terminated early.epi-simThe event ratesepi-simThe populationepi-simA new identifierepi-sim0The absolute time at which the simulation startsepi-sim-The duration of the simulation until it stopsepi-simA PRNG seed generated by the system's random number generator.epi-sim%A PRNG seed which is hard coded into  mwc-random.|}~~|}None#$8#epi-simA representation of the reconstructed tree, ie the tree where the leaves correspond to sequenced observations.epi-simA representation of the events that can be observed in an epidemic but which are not included in the reconstructed tree, ie the unsequenced observations.epi-simA wrapper for an b to indicate that this is an even that was observed rather than just an event of the epidemic process.epi-simExtract the events from an epidemic tree which are observed but not part of the reconstructed tree, ie the ones that are not sequenced.epi-sim3The reconstructed phylogeny obtained by pruning an ^ which contains represents the transmission tree of the epidemic. In the case where there are no sequenced samples in the epidemic then there is no tree to reconstruct which is why this function is in the either monad.epi-simThe events that were observed during the epidemic, ie those in the reconstructed tree and any unsequenced samples. If this is not possible an error message will be returned.epi-simA sorted list of all of the observations in the reconstructed tree.epi-simAggregate the sequenced and unsequenced individual level samples  None#$$oepi-sim6Class of types that can be expressed in Newick format.epi-sim+The person and time of the root of the tree(c) 2021 Alexander E. ZarebskiMIT,Alexander E. Zarebski unstableghcNone#$+Fepi-simThe number of people added or removed in an event. In the case of an extinction event the number of people removed is arbitrarily set to zero because this information is available from the prior event in the sequence.epi-sim-The first scheduled event after a given time.epi-simPredicate for whether there is a scheduled event during an interval. NOTE that this does not consider events that happen at the start of the interval as occurring between the times.tA = AbsoluteTime 1.0tB = AbsoluteTime 2.0 asTimed [(AbsoluteTime 1.5, 0.5)] Just False asTimed [(AbsoluteTime 2.5, 0.5)] Just True.noScheduledEvent tA tB <$> asTimed [(tA, 0.5)] Just Trueepi-sim$A list of the people involved in an b.epi-simPredicate for whether the first person infected the second in the given eventepi-sim?The people infected by a particular person in a list of events.epi-simRun the simulation until the specified stopping time and return a SimulationState+ which holds the history of the simulation.epi-simThe given timeepi-sim*The information about all scheduled eventsepi-simStart time for intervalepi-simEnd time for intervalepi-sim&Information about all scheduled eventsepi-simPotential infectorepi-simPotential infecteeepi-sim Given eventepi-simPotential infectorepi-simEventsepi-sim$time at which to stop the simulationepi-sim+the initial/current state of the simulation None #$0repi-simA new person constructed from the given identifier and a new identifier.epi-simA random person and the remaining group of people after they have been sampled with removal.epi-simRun a simulation described by a configuration object and the model's  allEvents% style function (see the example in "Epidemic.Model.InhomogeneousBDSCOD) using the provided PRNG.epi-sim0Run a simulation using a fixed PRNG random seed.epi-simRun a simulation described by a configuration object but using a random seed generated by the system rather than a seedepi-simPredicate for whether an epidemic event will appear as a leaf in the reconstructed tree. For scheduled sequenced samples this will only return true if there was at least one lineage observed.epi-simGenerate exponentially distributed random variates with inhomogeneous rate starting from a particular point in time. Assuming the stepFunc" is the intensity of arrivals and t0! is the start time this returns t1 the time of the next arrival.epi-simHelper function for converting between the Maybe monad and the Either monad.epi-sim Step functionepi-sim Start timeepi-sim Generator   None#$2\epi-simThe parameters of the logistic-BDSD process. This process allows for infections, removals, sampling and disasters.epi-simCreate an simulation configuration or return an error message if this is not possible.epi-sim=Defines how a single random event is simulated in this model.epi-sim.condition upon at least two sequenced samples.epi-sim values for termination handling.   (c) 2021 Alexander E. ZarebskiMIT,Alexander E. Zarebski unstableghcNone#$4epi-simThe population in which the epidemic occurs. This includes information about the number of people that have previously been infected and subsequently removed.epi-simConfiguration for the simulation of the inhomogeneous rates BDSCOD process.epi-sim'A random event and the state afterwardsepi-sim4Duration of the simulation after starting at time 0.epi-sim.condition upon at least two sequenced samples.epi-sim values for termination handling. None8"epi-sim&Return a BDS-process parameters objectNote that this requires that the rates are all positive, if they are not it will return Nothing.epi-simConfiguration of a inhomogeneous birth-death-sampling simulation.Note that this requires that the timed rates are all positive, if they are not it will return Nothing which can lead to cryptic bugs.epi-sim birth rateepi-sim death rateepi-sim sample rateepi-sim4Duration of the simulation after starting at time 0.epi-sim.condition upon at least two sequenced samples.epi-sim values for termination handling.epi-simBirth, Death and Sampling rates None:{epi-simbirth rate, death rate, sampling rate, catastrophe specification, occurrence rate and disaster specificationepi-simConfiguration of a birth-death-sampling-occurrence-disaster simulationepi-sim;The way in which random events are generated in this model.epi-simDuration of the simulationepi-sim.condition upon at least two sequenced samples.epi-sim values for termination handling.epi-simBirth, Death, Sampling, Catastrophe probability, Occurrence rates and Disaster probabilities Safe-Inferred: !"#$%&'()*+,-..//012234567789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                                               $epi-sim-0.7.0-DViI2uXntfg6JZVuToo6fhEpidemic.Types.PopulationEpidemic.Types.TimeEpidemic.Types.ParameterEpidemic.Types.EventsEpidemic.Types.SimulationEpidemic.Types.ObservationsEpidemic.Types.NewickEpidemicEpidemic.UtilityEpidemic.Model.LogisticBDSD"Epidemic.Model.InhomogeneousBDSCODEpidemic.Model.InhomogeneousBDSEpidemic.Model.BDSCOD Paths_epi_simPeoplePerson Identifier PopulationsusceptiblePeopleinfectiousPeople removedPeople isInfectedasPeopleincludesPersonhaveCommonPeople nullPeople numPeople addPerson removePersonpersonByteString$fToJSONIdentifier$fFromJSONIdentifier$fToJSONPerson$fFromJSONPerson$fToJSONPeople$fFromJSONPeople $fShowPeople $fEqPeople$fGenericPeople $fShowPerson$fGenericPerson $fEqPerson$fShowIdentifier$fGenericIdentifier$fEqIdentifierTimed TimeIntervaltimeIntEndPointstimeIntDuration TimeDelta TimeStampabsTimeisAfterisBefore AbsoluteTime timeDeltatimeAfterDelta timeInterval1 timeInterval2 inIntervalasConsecutiveIntervals1asTimed isAscending cadlagValuediracDeltaValuehasTimenextTimeallTimes allValuesmaybeNextTimed$fToJSONAbsoluteTime$fFromJSONAbsoluteTime$fTimeStampAbsoluteTime$fToJSONTimeDelta$fFromJSONTimeDelta$fToJSONTimeInterval$fFromJSONTimeInterval$fSemigroupTimed $fToJSONTimed$fFromJSONTimed$fGenericTimed $fEqTimed $fShowTimed$fGenericTimeInterval$fEqTimeInterval$fShowTimeInterval$fGenericTimeDelta $fEqTimeDelta$fShowTimeDelta$fOrdTimeDelta$fGenericAbsoluteTime$fEqAbsoluteTime$fShowAbsoluteTime$fOrdAbsoluteTime ProbabilityRateModelParametersrNaught eventRate birthProb eventWeights EpidemicTreeBranchLeafShoot EpidemicEvent InfectionRemovalIndividualSamplePopulationSample Extinction StoppingTime indSampTime indSampPerson indSampSeq popSampTime popSampPeople popSampSeqisIndividualSampleisExtinctionOrStopping derivedFrommaybeEpidemicTree$fOrdEpidemicEvent$fTimeStampEpidemicEvent$fToJSONEpidemicEvent$fFromJSONEpidemicEvent$fShowEpidemicTree$fEqEpidemicTree$fShowEpidemicEvent$fGenericEpidemicEvent$fEqEpidemicEventTerminationHandlerSimulationRandEventSimulationStateTerminatedSimulationSimulationConfigurationscRates scPopulationscNewIdentifier scStartTime scSimDurationscTerminationHandlerscRequireCherrygenIOFromWord32genIOFromSystemgenIOFromFixed$fEqSimulationState$fShowSimulationStateReconstructedTreeRBranchRLeafPointProcessEvents ObservationpointProcessEventsmaybeReconstructedTreeobservedEventsreconstructedTreeEvents aggregated$fTimeStampObservation$fToJSONObservation$fFromJSONObservation$fShowReconstructedTree$fEqReconstructedTree$fShowObservation$fOrdObservation$fEqObservation$fGenericObservationNewickasNewickStringampersandBuilder colonBuilderleftBraceBuilderrightBraceBuilder commaBuildercatastrophePeopleBuilder$fNewickReconstructedTree eventPopDeltafirstSchedulednoScheduledEventpersonsInEventpeopleInEventsinfected infectedBy allEventsinitialIdentifier newPerson randomPersonsimulationWithGenIOsimulationWithFixedSeedsimulationWithSystemisReconTreeLeafinhomExponential maybeToRight$fShowNSubtree$fShowNBranchSet $fShowNBranch $fShowNTree $fEqNTree $fEqNSubtree$fEqNBranchSet $fEqNBranchLogisticBDSDPopulationLogisticBDSDParametersparamsBirthRateparamsCapacityparamsDeathRateparamsSamplingRateparamsDisasters configuration randomEvent"$fPopulationLogisticBDSDPopulation=$fModelParametersLogisticBDSDParametersLogisticBDSDPopulation$fShowLogisticBDSDPopulation$fShowLogisticBDSDParametersInhomBDSCODPopipInfectedPeopleipNumRemovedByDeathipNumRemovedBySamplingipNumRemovedByCatastropheipNumRemovedByOccurrenceipNumRemovedByDisasterInhomBDSCODRates irBirthRate irDeathRateirSamplingRateirCatastropheSpecirOccurrenceRateirDisasterSpecgetNumRemovedByDeathgetNumRemovedBySamplinggetNumRemovedByCatastrophegetNumRemovedByOccurrencegetNumRemovedByDisaster$fPopulationInhomBDSCODPop/$fModelParametersInhomBDSCODRatesInhomBDSCODPop$fShowInhomBDSCODPop$fShowInhomBDSCODRates$fEqInhomBDSCODRates InhomBDSPop InhomBDSRates inhomBDSRates$fPopulationInhomBDSPop)$fModelParametersInhomBDSRatesInhomBDSPop$fShowInhomBDSPopBDSCODPopulationBDSCODParameters$fPopulationBDSCODPopulation1$fModelParametersBDSCODParametersBDSCODPopulation$fShowBDSCODPopulationversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName