Price of Security Transaction

Stephen George's Avatar

Stephen George

21 Jun, 2024 03:00 PM

I have tried to enter the folowing information as a security purchase (a Buy action)
Number of shares: 50
Price: 68.881
Fee 6.95
Upon entering this information, the price is changed to 68.88 and the calculated Amount is incorrect. I have compensated by adjusting the fee to obtain the correct Amount.

Oddly, if I change the number of shares to 500, the 68.881 price is accepted but when the number of shares are returned to 50 the price reverts back to 68.88. Not sure why the number of significant digits would change with the number of shares.

This may be a minor bug but I thought I would report it.

  1. 1 Posted by Stuart Beesley ... on 21 Jun, 2024 03:15 PM

    Stuart Beesley (Mr Toolbox)'s Avatar

    And what’s the correct total amount?

  2. 2 Posted by Stephen George on 21 Jun, 2024 03:57 PM

    Stephen George's Avatar

    First for clarity, I did a typo on the price. The actual price was $66.8881. The correct amount would be $3,351.36.

    Please note: I am quoting US$ entered in a US$ account.

    50 shares at a $66.8881 share price with a $6.95 fee would be $3,351.36 (rounded from $3,351.355 using the calculation 50 * 66.8881 +6.95)

    50 shares at $66.888 share price with a $6.95 fee gives $3,351.35 (no rounding required $,351.35 using the calculation 50 * 66.888 + 6.95). Because Moneydance would not accept the $66.8881 price I compensated by changing the fee to $6.96.

    For fun, I tried entering a price of $66.8882 and Moneydance accepted it.

    Sorry for the typo

  3. 3 Posted by Stuart Beesley ... on 21 Jun, 2024 04:57 PM

    Stuart Beesley (Mr Toolbox)'s Avatar

    Well the way MD works is after the txn is entered, it divides the amount by the qty to derive the accurate price based on the amount.. To be correct, you should just enter the txn and then edit the amount back to 3351.36, not by adjusting the fee. Then the price would recalculate back to 66.8882.

    I guess we can debate all day whether 3344.405 should round up/down....

  4. Support Staff 4 Posted by Sean Reilly on 21 Jun, 2024 06:45 PM

    Sean Reilly's Avatar

    Hi Stephen,

    As Stuart mentions, the best way to do this is to enter the exact number of shares and the amount. Moneydance records those as exact values without any rounding. The only time the rounding comes into play is when performing calculations such as ROI, Cost Basis, as well as when auto-adjusting the amount when you type to change the price.

    As for rounding 3344.405, that should round up to 3344.41 :)


    Sean Reilly
    Developer, The Infinite Kind

  5. 5 Posted by Stephen George on 21 Jun, 2024 08:20 PM

    Stephen George's Avatar

    Just to clarify. Moneydance works back from the amount and recalculates the Price by deducting the Fee from the Amount then dividing by the number of shares.

    Price = (3,351.36 - 6.95)/50 = 66.8882

    On the day of the trade I am given the price and the quantity but not the total amount of the transaction. In future when I see Moneydance readjusting the price, I will know there is a round off error involved.

    You are correct about whether $3,351.355 should be rounded up or down. My spreadsheet rounds up but I have seen other software round down. The institution rounded up on a ‘Buy’ but I wonder if they would do the same on a ’Sell’.

    Thanks for the explanation

  6. 6 Posted by Stephen George on 21 Jun, 2024 08:45 PM

    Stephen George's Avatar

    Thanks Sean,

    When I complete a trade, I only know the Price, number of Shares and my Fee. I will know the Amount a day later. In future when I see Moneydance readjusting my price, I will know it is a round off error involved and will enter the amount. It will be $0.01 higher, knowing the Institution is rounding up. I can always correct the next day when the amount is confirmed.

    Well there are two of us that agree 3344.405 should be rounded up to 3344.41 :)



Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac