Fix realized capital gains calculation and add period adjustment#5666
Fix realized capital gains calculation and add period adjustment#5666Morpheus1w3 wants to merge 1 commit intoportfolio-performance:masterfrom
Conversation
|
At name.abuchen.portfolio.ui/src/name/abuchen/portfolio/ui/views/dashboard/PerformanceCalculationWidget.java a minor Bugfix Was implemented. For example "Cash Fremdwährungsgewinne" is basically an addition. However, it could happen that the amount is negative. So it' lead into confusion, if the calculation method is an addition, but the amount is negative and subtracted. |
|
closes: #5662 |
|
Thanks for this :) |
e2089c2 to
e7394b7
Compare
This change improves how realized capital gains are calculated and displayed. Previously, realized gains were based on market values at the start of the reporting period. This could lead to confusing results, especially when assets were bought before the selected period. With this change: Realized gains are now calculated using the actual purchase cost (FIFO or moving average). A new adjustment line is added to keep the overall calculation consistent. The adjustment ensures that only gains within the selected period are reflected in the result. This makes the output easier to understand and closer to how users expect gains to be calculated. No changes to total portfolio value or performance logic were introduced.
e7394b7 to
9ec5bd2
Compare
|
Hmm if this goes through we need to be extra extra clear about what are those two new values. What is the meaning of the 336.8 EUR value ? My understanding is that it was simply not the task of Performance/Calculation to provide such kind of values. Maybe Trades view or Payment/Closed Trades view or the Trades Profit/Loss widget are more usable for this kind of topic. But each of them have different characteristics but we can work on them:
(before tax and fees = without tax and fees = pure price gains) Another thing, I am assuming those "taxable gains" determination should be gains AFTER fees, right ? But the Performance Calculation view only provides Gains that are before tax and fees. So if you calculate your taxable gains from this view, then it means you consider that you have to pay tax on pure price gain, not yet reduced by the differents fees. So you consider you have to pay taxes on your fees.. All in all, PP is not made for tax calculation. |
|
Existing calculation method is even misleading. Alternative proposal as below. Calculation Method (Performance) |
|
Even "Portfolio Performance is focusing the performance of investments, t" . the calculation on performance when Securities have been sold the profit must be calculated on initial price paid and not on the last cotation. If fact it's the case on curent year just apprear to be different if the acquisition was made the previous year. |
This change improves how realized capital gains are displayed in the performance calculation.
The existing period-based realized gains remain unchanged.
A new purchase-based realized gains line is added. It uses the actual historical purchase cost, based on FIFO or moving average. This helps users compare sales in the selected period against the original purchase cost.
A new adjustment line is added to keep the overall period-based performance calculation consistent.
The total portfolio value and the existing performance logic are not changed.
####Review note
The purchase-based value is built from transactions before the reporting period, so sales inside the selected period can be compared against the historical purchase cost.
The adjustment line keeps the existing period-based performance calculation consistent.