Closed patrickdugan closed 1 year ago
We chain counter-parties together using the same settlement algo that we use for swaps and futures but in the CalculatePNL function we use:
if "call"
SettlementPNL = if(settlement_price<strike){0-entry}else{(settlement_price - strike)-entry};
If "put"
SettlementPNL = if(settlement_price>strike){0-entry)else{(strike - settlement_price)-entry};
We chain counter-parties together using the same settlement algo that we use for swaps and futures but in the CalculatePNL function we use:
if "call"
SettlementPNL = if(settlement_price<strike){0-entry}else{(settlement_price - strike)-entry};
If "put"
SettlementPNL = if(settlement_price>strike){0-entry)else{(strike - settlement_price)-entry};