fig_carrier_total_bookings¶
-
passengersim.contrast.fig_carrier_total_bookings(summaries, raw_df=
False, orient: 'h' | 'v' ='h', ratio: str | bool ='all', *, width: int =500, also_df: bool =False)[source]¶ Generate a figure contrasting carrier total bookings for one or more runs.
- Parameters:
- summaries : dict[str, SimulationTables]¶
One or more SimulationTables to compare.
- raw_df : bool, default False¶
Return only the raw data used to generate the figure.
- orient : {'h', 'v'}, default 'h'¶
Chart orientation;
'h'for horizontal bars,'v'for vertical.- ratio : str or bool, default "all"¶
Add tooltip(s) giving the percentage change of each carrier’s bookings relative to a reference source. Pass a source-label string to specify the reference, or
'all'to compare against all other sources.- width : int, default 500¶
Width of each bar panel in pixels.
- also_df : bool, default False¶
If True, return a tuple of
(figure, dataframe)instead of just the figure.
- Returns:
alt.Chart or pd.DataFrame or tuple[alt.Chart, pd.DataFrame] – The Altair chart, or the raw DataFrame if
raw_dfis True, or a(chart, dataframe)tuple ifalso_dfis True.