Hi Stefano,

Am 16.08.23 um 17:12 schrieb Stefano Mihai Canta:
Thank you, Andreas!

I am running a small example, how do I get reinvested dividends to show up in the charts? If I split up the dividend transaction so that the dividend amount goes into the cash account first and then from the cash account to the commodity, I get the dividend amount to show up in the beangrow chart, but not when the dividend is reinvested directly into the commodity.

2023-06-23 * "reinvest" "[VTSAX] Vanguard Total Stock Market Index Fund"
   Assets:Investments:Retirement:VTSAX  0.878 VTSAX {105.48974943052393 USD}
   Income:Retirement:Investments:VTSAX:Dividend  -92.62 USD

vs

2023-06-23 * "reinvest" "[VTSAX] Vanguard Total Stock Market Index Fund"
   Assets:Investments:Retirement:VTSAX  0.878 VTSAX {105.48974943052393 USD}
   Assets:Investments:Retirement:Cash -92.62 USD

2023-06-23 * "reinvest" "[VTSAX] Vanguard Total Stock Market Index Fund"
   Assets:Investments:Retirement:Cash 92.62 USD
   Income:Retirement:Investments:VTSAX:Dividend  -92.62 USD

Thoughts?

I think the second way is the correct way. If it is a distributing ETF, the dividends will be paid out to your cash account first, and then you have to create a new transaction to buy more shares.

You can use

1980-05-12 custom "fava-extension" "fava_portfolio_returns" "{
  'beangrow_config': 'beangrow.pbtxt',
  'beangrow_debug_dir': 'debug',
}"

to instruct beangrow to write debug files to the debug folder. https://beancount.github.io/docs/calculating_portolio_returns.html#handling-transactions-using-the-signature explains how beangrow is categorizing and handling transactions.


Cheers,
Andreas


Stefano

On Sat, Aug 12, 2023 at 11:07 AM Andreas Gerstmayr <andr...@gerstmayr.me <mailto:andr...@gerstmayr.me>> wrote:

    Hi all,

    I developed a Fava extension which integrates portfolio reports
    generated by the excellent beangrow library [1] in Fava:
    https://github.com/andreasgerstmayr/fava-portfolio-returns
    <https://github.com/andreasgerstmayr/fava-portfolio-returns>

    Currently the report is almost identical to the one generated by
    beangrow, with an additional Profit and Loss chart (market value -
    spent
    amount over time) and some interactivity (mouse tooltips etc.).

    Ideally I'd like to keep all/most calculations in beangrow, and put
    only
    the report/frontend code in the Fava extension. My goal is to
    explicitly
    not reinvent the wheel of computing the portfolio returns :).


    [1] https://github.com/beancount/beangrow
    <https://github.com/beancount/beangrow>

    Cheers,
    Andreas

-- You received this message because you are subscribed to the Google
    Groups "Beancount" group.
    To unsubscribe from this group and stop receiving emails from it,
    send an email to beancount+unsubscr...@googlegroups.com
    <mailto:beancount%2bunsubscr...@googlegroups.com>.
    To view this discussion on the web visit
    
https://groups.google.com/d/msgid/beancount/d43aec17-b973-6a00-8c42-f592afd85f45%40gerstmayr.me
 
<https://groups.google.com/d/msgid/beancount/d43aec17-b973-6a00-8c42-f592afd85f45%40gerstmayr.me>.

--
You received this message because you are subscribed to the Google Groups "Beancount" group. To unsubscribe from this group and stop receiving emails from it, send an email to beancount+unsubscr...@googlegroups.com <mailto:beancount+unsubscr...@googlegroups.com>. To view this discussion on the web visit https://groups.google.com/d/msgid/beancount/CAMzm8_q3DYvKq%3DXYZyWjf-kwf7%3D58JVnK1%2B%2B_%2B%3DKJFjYjd7qrw%40mail.gmail.com <https://groups.google.com/d/msgid/beancount/CAMzm8_q3DYvKq%3DXYZyWjf-kwf7%3D58JVnK1%2B%2B_%2B%3DKJFjYjd7qrw%40mail.gmail.com?utm_medium=email&utm_source=footer>.

--
You received this message because you are subscribed to the Google Groups 
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to beancount+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beancount/fa01017b-910b-fd28-038b-0c1cac57b1be%40gerstmayr.me.

Reply via email to