ForecastData

class passengersim.core.ForecastData(label: str, mean_to_departure: DataFrame, stdev_to_departure: DataFrame, mean_in_timeframe: DataFrame, stdev_in_timeframe: DataFrame, history_sold_priceable: DataFrame = None, history_sold_yieldable: DataFrame = None, history_closure: DataFrame = None, dcp_days_prior: tuple[int] = (), adjusted_price: DataFrame = None)[source]

Bases: object

Methods

__init__(label, mean_to_departure, ...[, ...])

dashboard([tile_height, tile_width])

from_dataframe(df[, dcp_days_prior])

to_dataframe()

Attributes

adjusted_price

Adjusted fare by timeframe and booking class, or None if not collected.

adjusted_price : DataFrame | None = None

Adjusted fare by timeframe and booking class, or None if not collected.

Only path forecasts carry this. Cells are NaN once a class has closed under its advance purchase restriction.

dashboard(tile_height=240, tile_width=300)[source]
to_dataframe()[source]
classmethod from_dataframe(df: DataFrame, dcp_days_prior: tuple[int] | None = None)[source]