- visualise_single_pair(state, candle_universe, start_at=None, end_at=None, pair_id=None, height=800, axes=True, technical_indicators=True, title=True, theme='plotly_white', volume_bar_mode=VolumeBarMode.overlay)[source]#
Visualise single-pair trade execution.
The recorded state of the strategy execution.
You must give either state or positions.
The visualised pair in the case the strategy contains trades for multiple pairs.
If the strategy contains trades only for one pair this is not needed.
candle_universe (tradingstrategy.candle.GroupedCandleUniverse | pandas.core.frame.DataFrame) – Price candles we used for the strategy
height – Chart height in pixels
start_at (Optional[Union[Timestamp, datetime]]) – When the backtest started or when we crop the content
end_at (Optional[Union[Timestamp, datetime]]) – When the backtest ended or when we crop the content
axes – Draw axes labels
Extract technical indicators from the state and overlay them on the price action.
Only makes sense if the indicators were drawn against the price action of this pair.
Draw the chart title.
Set to string to give your own name.
Set True to use the state name as a title. TODO: True is a legacy option and will be removed.
theme – Plotly colour scheme to use
- Return type: