EoN.Simulation_Investigation.add_timeseries

Simulation_Investigation.add_timeseries(ts_data, color_dict=None, label=None, tex=None, **kwargs)[source]

This allows us to include some additional timeseries for comparision with the simulation. So for example, if we perform a simulation and want to plot the simulation but also a prediction, this is what we would use.

Arguments:
ts_data a pair (t, D)
where t is a numpy array of times and D is a dict where D[status] is the number of individuals of given status at corresponding time.
color_dict dict (default None)
a dictionary mapping statuses to the color desired for their plots. Defaults to the same as the simulation
label (string)
The label to be used for these plots in the legend.
tex (boolean)
Tells whether status should be rendered in tex’s math mode in labels. Defaults to whatever was done for creation of this simulation_investigation object.
**kwargs
any matplotlib key word args to affect how the curve is shown.
Returns:

ts timeseries object

Modifies:

This adds the timeseries object ts to the internal _time_series_list_