docstr: Calculates the cash flow from executing the given transaction
docstr_tok: ["Calculates","the","cash","flow","from","executing","the","given","transaction"]
code: def _calculate_execution_cash_flow(txn):
      """
      Calculates the cash flow from executing the given transaction
      """
      if isinstance(txn.asset, Future):
          return 0.0
  
      # When running on live mode and the commission is reduced from the
      # quote, means that the commission will be reduced from the cash
      # (added to capital_used)
      if txn.is_quote_live:
          return -1 * txn.price * txn.amount - txn.commission
  
      return -1 * txn.price * txn.amount
  
imports: from __future__ import division
  import logbook
  import numpy
  from collections import namedtuple
  from catalyst.assets import Future
  from six import itervalues, iteritems
  import catalyst.protocol
  from catalyst.constants import LOG_LEVEL
label_desc: Use image node_id 18 for calling the PerformancePeriod obj's underlying member method code with example usage: obj._calculate_execution_cash_flow(txn) and returns: unknown, int, unknown