Skip to content

Support for "closed positions earnings" #337

Description

@RaffaeleBianc0

Problem Statement
I sold some of my positions.
I would like to track the earnings/losses also on those - like Yahoo Finance shows in my overall portfolio stats.

Proposed Solution
Open / Closed / All earnings on the top of the page would be great, maybe optional, maybe on multiple lines.
This could be even further improved, with additional (optional) values like earnings/year, net earnings (considering a tax on withdrawals), net earnings/year.
For us users, this could be a new set of parameters in the YAML configuration file, like:

<usual general options here>
<usual general options here>
<usual general options here>
tax: 26%                    # this is to be used to calculate the net earnings; no impact on losses; if missing, then no tax calculation needed
starting-date: 2024-08-21   # this is used for the earnings/year and net earnings/year values
show-earnings: true         # this is to add 1 or 2 more lines on the topmost area, to show the new calculated values
groups:
  - name: My ETF Portfolio
    holdings:  
      - <as usual here>
      - <as usual here>
      - <as usual here>
    closed:                                   # new group, to be used only if I want the earnings calculation this issue is suggesting
      - name: VWCE as suggested by Bob        # Any text string supported here, no need to be a ticker
        balance: 1234.56                      # Positive numbers for earnings
      - name: Bitcoins i bought while drunk   # Any text string supported here
        balance: -543.21                      # Negative numbers for losses

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions