IBKR AutoFX leading to rounding errors

Hello,

It seems that the AutoFX made by IBKR could lead to some rounding errors resulting in a difference of a few cents in the accounts. That may accumulate over time. Below a clear example for my case:

  • In the activity statement, the forex trade is separated into two entries:
    209.89 USD.CHF @ 0.908109634 for 190.60 CHF
    0.00413323 USD.CHF @ 0.90619152 for 0 CHF
    Resulting in 209.89 USD for 190.60 CHF

  • In the transactions history (what will be imported in PP with the flex query), the forex trade is separated into 4 transactions:
    209.00 USD.CHF @ 0.9081 β†’ 189.79 CHF
    0.06 USD.CHF @ 0.9068 β†’ 0.05 CHF
    0.83 USD.CHF @ 0.9081 β†’ 0.75 CHF
    0.00 USD.CHF @ 0.9062 β†’ 0.00 CHF
    Resulting into 209.89 USD changed from 190.59 CHF

Instead of rounding each transactions individually, would it be possible to combine the same type of transactions together before rounding them? Or avoid rounding them to 2 decimals only?

Thanks in advance,
Best regards

Can you post the exact activity statement XML of that example here? I would help to better understand the context.

As the models are slightly different, we may not be able to change the splitting, but could try to correct for rounding errors.

Here it is: (without the first β€œ<” since the message is hidden if I let it)

Trade accountId=β€œU00000000” acctAlias=β€œβ€ model=β€œβ€ currency=β€œCHF” fxRateToBase=β€œ1” assetCategory=β€œCASH” subCategory=β€œβ€ symbol=β€œUSD.CHF” description=β€œUSD.CHF” conid=β€œ12087820” securityID=β€œβ€ securityIDType=β€œβ€ cusip=β€œβ€ isin=β€œβ€ figi=β€œβ€ listingExchange=β€œβ€ underlyingConid=β€œβ€ underlyingSymbol=β€œβ€ underlyingSecurityID=β€œβ€ underlyingListingExchange=β€œβ€ issuer=β€œβ€ issuerCountryCode=β€œβ€ tradeID=β€œ7164893392” multiplier=β€œ1” relatedTradeID=β€œβ€ strike=β€œβ€ reportDate=β€œ20250121” expiry=β€œβ€ dateTime=β€œ20250121;155408” putCall=β€œβ€ tradeDate=β€œ20250121” principalAdjustFactor=β€œβ€ settleDateTarget=β€œ20250122” transactionType=β€œExchTrade” exchange=β€œIDEALFX” quantity=β€œ209” tradePrice=β€œ0.90811” tradeMoney=β€œ189.79499” proceeds=β€œ-189.79499” taxes=β€œ0” ibCommission=β€œ0” ibCommissionCurrency=β€œCHF” netCash=β€œ0” closePrice=β€œ0” openCloseIndicator=β€œβ€ notes=β€œAFx;P” cost=β€œ0” fifoPnlRealized=β€œ0” mtmPnl=β€œ-0.47861” origTradePrice=β€œ0” origTradeDate=β€œβ€ origTradeID=β€œβ€ origOrderID=β€œ0” origTransactionID=β€œ0” buySell=β€œBUY” clearingFirmID=β€œβ€ ibOrderID=β€œ3757406423” transactionID=β€œ30989161631” ibExecID=β€œ0000d5db.67ae5650.01.01” relatedTransactionID=β€œβ€ rtn=β€œβ€ brokerageOrderID=β€œ016539e3.0001cc27.678f428e.0001” orderReference=β€œβ€ volatilityOrderLink=β€œβ€ exchOrderId=β€œN/A” extExecID=β€œ00013669.67c7e5da.01.01.cust” orderTime=β€œ20250121;155408” openDateTime=β€œβ€ holdingPeriodDateTime=β€œβ€ whenRealized=β€œβ€ whenReopened=β€œβ€ levelOfDetail=β€œEXECUTION” changeInPrice=β€œ0” changeInQuantity=β€œ0” orderType=β€œMKT” traderID=β€œβ€ isAPIOrder=β€œN” accruedInt=β€œ0” initialInvestment=β€œβ€ serialNumber=β€œβ€ deliveryType=β€œβ€ commodityType=β€œβ€ fineness=β€œ0.0” weight=β€œ0.0” />

Trade accountId=β€œU00000000” acctAlias=β€œβ€ model=β€œβ€ currency=β€œCHF” fxRateToBase=β€œ1” assetCategory=β€œCASH” subCategory=β€œβ€ symbol=β€œUSD.CHF” description=β€œUSD.CHF” conid=β€œ12087820” securityID=β€œβ€ securityIDType=β€œβ€ cusip=β€œβ€ isin=β€œβ€ figi=β€œβ€ listingExchange=β€œβ€ underlyingConid=β€œβ€ underlyingSymbol=β€œβ€ underlyingSecurityID=β€œβ€ underlyingListingExchange=β€œβ€ issuer=β€œβ€ issuerCountryCode=β€œβ€ tradeID=β€œ7164893719” multiplier=β€œ1” relatedTradeID=β€œβ€ strike=β€œβ€ reportDate=β€œ20250121” expiry=β€œβ€ dateTime=β€œ20250121;155408” putCall=β€œβ€ tradeDate=β€œ20250121” principalAdjustFactor=β€œβ€ settleDateTarget=β€œ20250122” transactionType=β€œExchTrade” exchange=β€œIDEALFX” quantity=β€œ0.06” tradePrice=β€œ0.90683” tradeMoney=β€œ0.0544098” proceeds=β€œ-0.0544098” taxes=β€œ0” ibCommission=β€œ0” ibCommissionCurrency=β€œCHF” netCash=β€œ0” closePrice=β€œ0” openCloseIndicator=β€œβ€ notes=β€œAFx;P” cost=β€œ0” fifoPnlRealized=β€œ0” mtmPnl=β€œ-0.000061” origTradePrice=β€œ0” origTradeDate=β€œβ€ origTradeID=β€œβ€ origOrderID=β€œ0” origTransactionID=β€œ0” buySell=β€œBUY” clearingFirmID=β€œβ€ ibOrderID=β€œ3757406423” transactionID=β€œ30989162064” ibExecID=β€œ0000d5db.67ae564a.01.01” relatedTransactionID=β€œβ€ rtn=β€œβ€ brokerageOrderID=β€œ016539e3.0001cc27.678f428e.0001” orderReference=β€œβ€ volatilityOrderLink=β€œβ€ exchOrderId=β€œN/A” extExecID=β€œ00013669.67c7e5d4.01.01.cust” orderTime=β€œ20250121;155408” openDateTime=β€œβ€ holdingPeriodDateTime=β€œβ€ whenRealized=β€œβ€ whenReopened=β€œβ€ levelOfDetail=β€œEXECUTION” changeInPrice=β€œ0” changeInQuantity=β€œ0” orderType=β€œMKT” traderID=β€œβ€ isAPIOrder=β€œN” accruedInt=β€œ0” initialInvestment=β€œβ€ serialNumber=β€œβ€ deliveryType=β€œβ€ commodityType=β€œβ€ fineness=β€œ0.0” weight=β€œ0.0” />

Trade accountId=β€œU00000000” acctAlias=β€œβ€ model=β€œβ€ currency=β€œCHF” fxRateToBase=β€œ1” assetCategory=β€œCASH” subCategory=β€œβ€ symbol=β€œUSD.CHF” description=β€œUSD.CHF” conid=β€œ12087820” securityID=β€œβ€ securityIDType=β€œβ€ cusip=β€œβ€ isin=β€œβ€ figi=β€œβ€ listingExchange=β€œβ€ underlyingConid=β€œβ€ underlyingSymbol=β€œβ€ underlyingSecurityID=β€œβ€ underlyingListingExchange=β€œβ€ issuer=β€œβ€ issuerCountryCode=β€œβ€ tradeID=β€œ7164893759” multiplier=β€œ1” relatedTradeID=β€œβ€ strike=β€œβ€ reportDate=β€œ20250121” expiry=β€œβ€ dateTime=β€œ20250121;155408” putCall=β€œβ€ tradeDate=β€œ20250121” principalAdjustFactor=β€œβ€ settleDateTarget=β€œ20250122” transactionType=β€œExchTrade” exchange=β€œIDEALFX” quantity=β€œ0.83” tradePrice=β€œ0.90811” tradeMoney=β€œ0.7537313” proceeds=β€œ-0.7537313” taxes=β€œ0” ibCommission=β€œ0” ibCommissionCurrency=β€œCHF” netCash=β€œ0” closePrice=β€œ0” openCloseIndicator=β€œβ€ notes=β€œAFx;P” cost=β€œ0” fifoPnlRealized=β€œ0” mtmPnl=β€œ-0.0019” origTradePrice=β€œ0” origTradeDate=β€œβ€ origTradeID=β€œβ€ origOrderID=β€œ0” origTransactionID=β€œ0” buySell=β€œBUY” clearingFirmID=β€œβ€ ibOrderID=β€œ3757406423” transactionID=β€œ30989162131” ibExecID=β€œ0000d5db.67ae565a.01.01” relatedTransactionID=β€œβ€ rtn=β€œβ€ brokerageOrderID=β€œ016539e3.0001cc27.678f428e.0001” orderReference=β€œβ€ volatilityOrderLink=β€œβ€ exchOrderId=β€œN/A” extExecID=β€œ00013669.67c7e5e4.01.01.cust” orderTime=β€œ20250121;155408” openDateTime=β€œβ€ holdingPeriodDateTime=β€œβ€ whenRealized=β€œβ€ whenReopened=β€œβ€ levelOfDetail=β€œEXECUTION” changeInPrice=β€œ0” changeInQuantity=β€œ0” orderType=β€œMKT” traderID=β€œβ€ isAPIOrder=β€œN” accruedInt=β€œ0” initialInvestment=β€œβ€ serialNumber=β€œβ€ deliveryType=β€œβ€ commodityType=β€œβ€ fineness=β€œ0.0” weight=β€œ0.0” />

Trade accountId=β€œU00000000” acctAlias=β€œβ€ model=β€œβ€ currency=β€œCHF” fxRateToBase=β€œ1” assetCategory=β€œCASH” subCategory=β€œβ€ symbol=β€œUSD.CHF” description=β€œUSD.CHF” conid=β€œ12087820” securityID=β€œβ€ securityIDType=β€œβ€ cusip=β€œβ€ isin=β€œβ€ figi=β€œβ€ listingExchange=β€œβ€ underlyingConid=β€œβ€ underlyingSymbol=β€œβ€ underlyingSecurityID=β€œβ€ underlyingListingExchange=β€œβ€ issuer=β€œβ€ issuerCountryCode=β€œβ€ tradeID=β€œ7165191720” multiplier=β€œ1” relatedTradeID=β€œβ€ strike=β€œβ€ reportDate=β€œ20250121” expiry=β€œβ€ dateTime=β€œ20250121;170000” putCall=β€œβ€ tradeDate=β€œ20250121” principalAdjustFactor=β€œβ€ settleDateTarget=β€œ20250122” transactionType=β€œExchTrade” exchange=β€œIDEALFX” quantity=β€œ0.00413323” tradePrice=β€œ0.90619152” tradeMoney=β€œ0.003745499” proceeds=β€œ-0.003745499” taxes=β€œ0” ibCommission=β€œ0” ibCommissionCurrency=β€œCHF” netCash=β€œ0” closePrice=β€œ0” openCloseIndicator=β€œβ€ notes=β€œβ€ cost=β€œ0” fifoPnlRealized=β€œ0” mtmPnl=β€œ-0.000001” origTradePrice=β€œ0” origTradeDate=β€œβ€ origTradeID=β€œβ€ origOrderID=β€œ0” origTransactionID=β€œ0” buySell=β€œBUY” clearingFirmID=β€œβ€ ibOrderID=β€œ3757572897” transactionID=β€œ30990533339” ibExecID=β€œCUSTHSFX.00a71c65.01.01” relatedTransactionID=β€œβ€ rtn=β€œβ€ brokerageOrderID=β€œβ€ orderReference=β€œβ€ volatilityOrderLink=β€œβ€ exchOrderId=β€œN/A” extExecID=β€œN/A” orderTime=β€œ20250121;170000” openDateTime=β€œβ€ holdingPeriodDateTime=β€œβ€ whenRealized=β€œβ€ whenReopened=β€œβ€ levelOfDetail=β€œEXECUTION” changeInPrice=β€œ0” changeInQuantity=β€œ0” orderType=β€œβ€ traderID=β€œβ€ isAPIOrder=β€œN” accruedInt=β€œ0” initialInvestment=β€œβ€ serialNumber=β€œβ€ deliveryType=β€œβ€ commodityType=β€œβ€ fineness=β€œ0.0” weight=β€œ0.0” />

Avoiding rounding the values in tradeMoney/proceeds should do the job.

1 Like