Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

No Format
$instrumentType = getInstrumentType($symbol);
if($instrumentType == INSTRUMENT_TYPE_OPTION) {
   return $quantity * 1.65;
} else {
   return $quantity * 0.0005;
}

Different rate for symbols that have Exchange code of OBB or PNK (Per Execution type)

No Format
$exchangeCode = getExchangeCode($symbol, $date);
if($exchangeCode == 'OBB' || $exchangeCode == 'PNK') {
 $fee = bcmul(bcmul($quantity, $price), '0.001'); // This is charging 10 basis pts of gross value
}
else $fee = bcmul($quantity, '0.001') ; // This is the per share rate for non-OBB/PNK activity
return $fee;

Different rate for Select Symbols (Per Execution type)

No Format
if(in_array($symbol, array('AA','BAC','C','MSFT','QQQ'))) {
   return bcmul($quantity, '0.001');
   } else return bcmul($quantity, '0.0015');

...