demand_to_come

passengersim.database.common_queries.demand_to_come(cnx: Database, *, scenario: str = None, burn_samples: int = 100) DataFrame[source]

Demand by market and timeframe across each sample.

This query delivers sample-by-sample timeframe demand results for the various markets (origin, destination, passenger type) in the simulation. It requires that the simulation was run while recording demand details (i.e. with the demand flag set on Config.db.write_items).

Parameters:
cnx : Database

scenario : str, optional

burn_samples : int, default 100

The demand will be returned ignoring this many samples from the beginning of each trial.

Returns:

pandas.DataFrame – The resulting dataframe is indexed by iteration, trial, sample, segment, orig, and dest; and has columns defined by the DCPs. The values stored are the total remaining demand to come at each DCP.