datasim.XYData¶
- class datasim.XYData(world, data_x: ~typing.List[float] = [], data_y: ~typing.List[float] = [], plot_options: ~datasim.types.PlotOptions = <datasim.types.PlotOptions object>)¶
Data with x and y values as float.
- __init__(world, data_x: ~typing.List[float] = [], data_y: ~typing.List[float] = [], plot_options: ~datasim.types.PlotOptions = <datasim.types.PlotOptions object>)¶
Create a data source from x and y lists of floats.
- Parameters:
world – The World this data belongs to.
data_x (List[float], optional) – x values. Defaults to [] to start with an empty data set.
data_y (List[float], optional) – y values. Defaults to [] to start with an empty data set.
plot_options (Optional[PlotOptions], optional) – Options for a plot. Defaults to default PlotOptions which means nothing will be plotted.
Methods
__init__
(world[, data_x, data_y, plot_options])Create a data source from x and y lists of floats.
append
(x, y)Add a data point to this data set.
Attributes
dataset
set_index
world
options