beancount / fava

Fava - web interface for Beancount
https://beancount.github.io/fava/
MIT License
1.97k stars 285 forks source link

Reducing visual discrepancies between operating and non-operating currencies in graph #1497

Closed Donearm closed 1 year ago

Donearm commented 2 years ago

Hi,

I have 3 operating currencies, EUR, PLN and USD, and the occasional other ones, mostly due to trips I do. Recently I added a few expenses in IDR, which operates in hundred of thousands and millions. Compared to the operating currencies' much smaller digits, the graph looks like this:

at_cost_large_difference_in_graphs

The small dot on the bottom right are the recent expenses in IDR (about 17M). Is there a way to ignore a currency in a graph when at cost? Scaling it to others will never work due to the big difference. Is there any other solution already implemented?

Thank you

yagebu commented 1 year ago

Is there any other solution already implemented?

No, sadly Fava doesn't deal too well with these sorts of situations.

I think allowing toggling of certain currencies (for example by clicking on the currency name in the chart legend) from the charts would be a valuable addition that would solve this sort of problem. A PR implementing this would be welcome :)

Donearm commented 1 year ago

Wish I was skilled enough in TS (and not super-busy) to do a PR myself :) I guess it would be even simpler to have an option to include only operating currencies in the graphs. That would suffice.

marvin-yorke commented 1 year ago

Might not be a perfect solution, but could be a workaround: since a) Beancount does not care about actual currencies, b) For one-off situations you likely would not use price fetchers, c) I've just checked and 1 EUR is like 16,000 IDR

You could create a phony currency like TIDR such that 1 TIDR = 10,000 IDR and use that in your entries, such that Account:A -17,543,500 IDR becomes Account:A -1,754.35 TIDR

Personally I'm in a similar situation, using EUR, USD and another currency that produces amounts that are orders of magnitude more, and I don't use "at cost" view altogether since numeric comparison of such vastly different values is useless, only "converted to" makes sense to me in this case

Donearm commented 1 year ago

Thanks for the idea @marvin-yorke. Personally I have opted to convert all those expenses in IDR to EUR for the time being (there are about 25 of them, not so much work once in a blue moon). Your workaround is cleaner though. If I happen to travel to another country with high-inflationary currency, I will opt for a phony currency until a fix is implemented.