ezyquant.backtesting.trade.SETTrade#

class ezyquant.backtesting.trade.SETTrade(matched_at: datetime, symbol: str, volume: float, price: float, pct_commission: float)#

SETTrade.

Parameters:
  • matched_at (datetime) – The time when the trade was executed.

  • symbol (str) – The symbol of the trade.

  • volume (float) – The volume of the trade positive is buy and negative is sell (must be multiple of 100).

  • price (float) – The price of the trade.

  • pct_commission (float) – The percentage of commission (must be between 0 and 1).

SETTrade.commission

Always positive.

SETTrade.value

Positive is Buy, Negative is Sell.

SETTrade.value_with_commission

Amount of cash reduced by this trade.

SETTrade.matched_at

SETTrade.symbol

SETTrade.volume

SETTrade.price

SETTrade.pct_commission