TradeSummary#

tradingstrategy.analysis.tradeanalyzer.TradeSummary Python class in Trading Strategy framework.

class TradeSummary[source]#

Bases: object

Some generic statistics over all the trades

__init__(won, lost, zero_loss, stop_losses, undecided, realised_profit, open_value, uninvested_cash, initial_cash, extra_return)#
Parameters:
  • won (int) –

  • lost (int) –

  • zero_loss (int) –

  • stop_losses (int) –

  • undecided (int) –

  • realised_profit (float) –

  • open_value (float) –

  • uninvested_cash (float) –

  • initial_cash (float) –

  • extra_return (float) –

Return type:

None

Methods

__init__(won, lost, zero_loss, stop_losses, ...)

to_dataframe()

Creates a human-readable Pandas dataframe table from the object.

Attributes

won

lost

zero_loss

stop_losses

undecided

realised_profit

open_value

uninvested_cash

initial_cash

extra_return

to_dataframe()[source]#

Creates a human-readable Pandas dataframe table from the object.

Return type:

DataFrame

__init__(won, lost, zero_loss, stop_losses, undecided, realised_profit, open_value, uninvested_cash, initial_cash, extra_return)#
Parameters:
  • won (int) –

  • lost (int) –

  • zero_loss (int) –

  • stop_losses (int) –

  • undecided (int) –

  • realised_profit (float) –

  • open_value (float) –

  • uninvested_cash (float) –

  • initial_cash (float) –

  • extra_return (float) –

Return type:

None