Net worth by day/week/month/year

James Howtt's Avatar

James Howtt

30 Aug, 2022 01:30 PM

I am trying to obtain a summary report for account balances or net worth for each day last year so I can post process in excel. The data is there to produce the graphs & single date report but without copying the single report down 365 times this is not possible.

Can you help?

Thanks

James

  1. 1 Posted by Stuart Beesley ... on 30 Aug, 2022 03:46 PM

    Stuart Beesley (Mr Toolbox)'s Avatar

    Look for Ric Werme‘s Networth Matrix script/extension. It may help. You should find links to it/him in this forum.

    Ric? Can you help?

  2. 2 Posted by Ric Werme on 30 Aug, 2022 08:10 PM

    Ric Werme's Avatar

    Thanks Stuart for keeping my hack in mind.

    James, I have something that may be very close to what you want.

    Check out all the discussion at https://infinitekind.tenderapp.com/discussions/general-questions/11...

    The data errors Jerry ran into are a substantial problem, but I can't reproduce them at home, I may have a smaller transaction database. I had to abandon that for a while to catch up on other stuff - I'm still working on other stuff, and will be for months.

    It's still working fine for me for the monthly summaries I wanted.

    I'd like to get back to it and revamp the code to not use some convenience routines. The result will be much faster and might avoid whatever weird stuff that is producing wrong data.

    The program is very safe - it only reads from the database. Even my early code never damaged the database.

    Play around with it if you'd like, I'd recommend only dumping a month's worth of daily data at first.

  3. 3 Posted by dalefurrow (Fel... on 31 Aug, 2022 07:51 PM

    dalefurrow (Fellow User)'s Avatar

    So for what it's worth, this net worth calc has been on my to-do list for a while, and pretty much all my reporting in moneydance is run headless through python at this point. So I added a net worth calculation for any given set of dates to my existing MD headless repo, specifically a module pyaccountrwapper.py which has a PyAccountrWapper class to hold the data and do the calculations, and a demo using the included test dataset here. I tested the output against our long-established investment reports package for investment reports, and then manually tested balances for savings, checking accounts, etc, and it worked correctly. I tried it on my personal data as well, and it checked out. Not really surprising, as all I'm really doing is leveraging existing methods in the moneydance jar to get balances and prices for each account. Please note that in the PyAccountWrapper class, I'm assuming that all accounts to be valued are children of the root account, unless the account is a security, which of course is a child of an investment account. It wouldn't be all that difficult to modify the code to recurse into a more nested account structure, but I've never had that as my use case.

    Anyway, that code is out there if you want to check it out--usual caveats, use at your own risk, please back up up your data before using this or any other script. The output looks like below.

    Thanks,
    Dale

    date parent_account account balance price total
    2009-08-24 00:00:00 Checking CASH 6074.67 1 6074.67
    2009-08-24 00:00:00 StockBrokerage1 CASH 12447.1 1 12447.1
    2009-08-24 00:00:00 StockBrokerage1 Dell 800 14.69 11752
    2009-08-24 00:00:00 StockBrokerage1 Vanguard S&P 500 Fund 172.214 94.84 16332.8
    2009-08-24 00:00:00 StockBrokerage2 CASH 6822.86 1 6822.86
    2009-08-24 00:00:00 StockBrokerage2 Financial Select Sector SPDR 217 14.44 3133.48
    2009-08-24 00:00:00 StockBrokerage6 CASH 31305.2 1 31305.2
    2009-08-24 00:00:00 StockBrokerage6 Dell -472 14.69 -6933.68
  4. System closed this discussion on 30 Nov, 2022 08:00 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? 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