Chartbreaker
    Preparing search index...

    Type Alias PortfolioValueHistoryPoint

    One point of a portfolio's end-of-day value history.

    type PortfolioValueHistoryPoint = {
        buyValue: NumericString;
        dateString: string;
        isProvisional?: boolean;
        realizedPnl: NumericString;
        realizedPnlAfterFees?: NumericString;
        value: NumericString;
    }
    Index
    buyValue: NumericString

    The original buy value of the open positions on that day, in the currency of the enclosing PortfolioValueHistoryResponse.

    dateString: string

    The day the value belongs to, YYYY-MM-DD (weekdays only).

    isProvisional?: boolean

    true on the current day, which is the one point of the series that is not finished yet.

    Its positions are the ones that are open right now, but the broker values them with the last end-of-day price there is. Where live prices are available this library re-values that point with them before emitting it, so that the chart's last point shows the same number as the depot itself; realizedPnl stays the broker's, which is correct as soon as the trade has been synced.

    realizedPnl: NumericString

    The profit/loss that has been realized by the trades closed on that day, before fees and taxes, in the currency of the enclosing PortfolioValueHistoryResponse.

    This is what has been booked on that single day, it is not cumulative: a cumulative curve can be built as a running sum over data, which is complete because the series starts at the first order execution.

    realizedPnlAfterFees?: NumericString

    The same as realizedPnl, but with the fees of those trades subtracted (still before taxes).

    A trade whose fees are not fully known contributes its gross profit/loss here, so that a single trade without fee data cannot blank out a day - and with it every cumulative curve drawn through it. Whether any fees are known at all is realizedFeesKnown of the enclosing response; where that is false this equals realizedPnl and should not be labelled as a net figure.

    It is 0 on days on which nothing has been closed. Missing only when talking to a backend that predates the realizedFeesKnown flag.

    The end-of-day value of the open positions on that day, in the currency of the enclosing PortfolioValueHistoryResponse.