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