Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

returns of -100.0% for short durations / large return numbers #14

Open
gety9 opened this issue Sep 19, 2021 · 0 comments
Open

returns of -100.0% for short durations / large return numbers #14

gety9 opened this issue Sep 19, 2021 · 0 comments

Comments

@gety9
Copy link

gety9 commented Sep 19, 2021

simple.beancount

option "operating_currency" "USD"
plugin "beancount.plugins.check_commodity"
plugin "beancount.plugins.implicit_prices"

2005-01-01 commodity USD
2005-01-01 commodity AAA

2019-01-01 open Assets:Investments:Cash     USD
2019-01-01 open Expenses:Investing:Fees     USD
2019-01-01 open Income:Investments:Gains    USD
2019-01-01 open Assets:Investments:AAA      AAA

2019-03-18 * "Buy AAA"
  Assets:Investments:AAA                    250 AAA {39.75 USD, 2019-03-18}
  Assets:Investments:Cash              -9937.50 USD

2019-03-20 * "Sell AAA"
  Assets:Investments:AAA                   -250 AAA {39.75 USD, 2019-03-18} @ 41.95 USD
  Expenses:Investing:Fees                  0.23 USD
  Income:Investments:Gains                 -550 USD
  Assets:Investments:Cash              10487.27 USD

conf-simple

investments {
  investment {
    currency: "AAA"
    asset_account: "Assets:Investments:AAA"
    cash_accounts: "Assets:Investments:Cash"
  }
}
groups {
  group {
    name: "currency.AAA"
    investment: "Assets:Investments:AAA"
  }
}

result
1_preFix
2019's return shown as 20%, X_years_ago returns shown as = -100%

result with fix of issue 4 of #4 (comment)
2_afterFix
all returns shown as -100%

The correct return is ~1852657.75%

I am not sure

  • if script crashes/fails to calculate the number
  • or if it simply can't display the number in return table cause it is such a large number

And though such a large return number is meaningless and not sustainable current outputs are deceptive, i think displaying order of magnitude 10^6% will be more appropriate.
(similarly if it's -1852657.75% then -10^6%)

@gety9 gety9 changed the title returns of -100.0% for short durations. returns of -100.0% for short durations / large return numbers. Sep 19, 2021
@gety9 gety9 changed the title returns of -100.0% for short durations / large return numbers. returns of -100.0% for short durations / large return numbers Sep 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant