How to fix the income statement so that incomes are positive and expenses are negative?

194 views
Skip to first unread message

John Mee

unread,
May 9, 2019, 2:44:22 AM5/9/19
to Beancount
Perhaps this is an issue of fava, I'm sure you'll redirect me if so... my problem is that fava's balance sheet shows assets as positive values and equity as negative (which is also odd, imho both sides should be positive values?) thence the income Statement shows income as negative and expenses as positives.

I started mucking around with code to try and flip all my beancount text file entries from positives to negatives but, given that is "work, (eg: got so far as to be searching for routine in beancount.data that outputs Transaction instance as beancount text?), that now I'm reconsidering my approach.  Even if I do flip it all successfully my balance sheet will show assets as negatives, equity as positives, income as positive and expenses as negative: better but still not "right" imho (please correct me as appropriate).

Ultimately I (think I) would like fava's income statement to list income in positive values; expenses can be either positive or negative I don't particularly care, but it would be nice if both sides of the balance sheet were positive although I can live with whatever I get on that. 

(First) Question is perhaps: Should I proceed to invert every entry in beancount, or focus on "fixing" fava?

thanks.

John Mee

unread,
May 9, 2019, 3:26:54 AM5/9/19
to Beancount
beancount-web produces the same outputs of positive and negatives, so it's not fava's fault?
Perhaps I need education as to how things to think of things on balance sheets and income statements.

ie on reports:
 assets +'ve & equity -'ve  === income -'ve & expenses +'ve?
vs
 assets- & equity+ === income+ & expenses-
vs
 everything +'ve.

I lean toward thinking everything should be positive values; in your opinion, considering the books from a personal point-of-view, should assets be positive or negative? liabilities/income/expenses??

Martin Michlmayr

unread,
May 9, 2019, 3:44:04 AM5/9/19
to bean...@googlegroups.com
* John Mee <*@johnmee.com> [2019-05-09 00:26]:
> beancount-web produces the same outputs of positive and negatives,
> so it's not fava's fault?

You may want to read this introduction to find out why income, equity
and liabilities are negative in beancount:
https://docs.google.com/document/d/100tGcA4blh6KSXPRGCZpUlyxaRUwFHEvnz_k9DyZFn4/edit

> I lean toward thinking everything should be positive values

beancount doesn't use debits and credits; it uses plus and minus
instead.

> in your opinion, considering the books from a personal
> point-of-view, should assets be positive or negative?

Assets are positive

> liabilities/income/expenses??

Liabilities and income are Negative, expenses are positive.

This way, things balance.
--
Martin Michlmayr
https://www.cyrius.com/

Florian Lindner

unread,
May 9, 2019, 3:50:33 AM5/9/19
to Beancount
Am 09.05.19 um 08:44 schrieb John Mee:> Perhaps this is an issue of fava, I'm sure you'll redirect me if so... my problem is that fava's balance sheet shows assets as positive values and equity as negative (which is also odd, imho both sides should be positive values?) thence the income Statement shows income as negative and expenses as positives.

>
> I started mucking around with code to try and flip all my beancount text file entries from positives to negatives but, given that is "work, (eg: got so far as to be searching for routine in beancount.data that outputs Transaction instance as beancount text?), that now I'm reconsidering my approach.  Even if I do flip it all successfully my balance sheet will show assets as negatives, equity as positives, income as positive and expenses as negative: better but still not "right" imho (please correct me as appropriate).
>
> Ultimately I (think I) would like fava's income statement to list income in positive values; expenses can be either positive or negative I don't particularly care, but it would be nice if both sides of the balance sheet were positive although I can live with whatever I get on that.
>
> (First) Question is perhaps: Should I proceed to invert every entry in beancount, or focus on "fixing" fava?
Hello,

if I understand you correctly, that's the way double-entry accounting works.

You receive X money: Your employer pays to your checkings account: Income -> Assets. Since money is moved from Income to Assets, now your income is negative X and your Assets is postive X.
Same with Equity. Equity is an account for something you already have. It's also used for Opening Balances. In order to start an Asset account you need to fill it with money at the point in time you decide to start accounting. For that, you book that amount from Equity:Opening-Balances (which goes negative then) to Assets (which goes positive by the same amount).

Now, if you something, you book the money from Assets to Expenses, resulting in a negative change in Assets and a positive change in Expenses.

Hope that helped a bit,

Best,
Florian

Zhuoyun Wei

unread,
May 9, 2019, 4:51:34 AM5/9/19
to Beancount
I understand you.

The problem here is that Beancount does not use traditional double-entry terms like "credit" and "debit" for different types of accounts. It uses signs. It uses this modified account equation:

(Income + Liabilities) + (Assets + Expenses) + Equity = 0

So, in most cases, Income and Liabilities are negative, while Assets and Expenses are positive.

I have been using Beancount for more than 3 years, so I am already attuned to its usage of negative and positive signs. But your post reminds me that if a user has used tranditonal double-booking method before, they may feel confused facing the Income Statement in Beancount.

Perhaps Fava could provide a fava-option that flips the signs to generate a "traditional" Income Statement and Balance Sheet?

--
Zhuoyun Wei
> --
> 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+...@googlegroups.com.
> To post to this group, send email to bean...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beancount/a06f3d41-4aa9-4a92-87b3-1efd16ff1c49%40googlegroups.com <https://groups.google.com/d/msgid/beancount/a06f3d41-4aa9-4a92-87b3-1efd16ff1c49%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.

Stefano Zacchiroli

unread,
May 9, 2019, 5:18:48 AM5/9/19
to bean...@googlegroups.com
On Thu, May 09, 2019 at 04:51:15AM -0400, Zhuoyun Wei wrote:
> Perhaps Fava could provide a fava-option that flips the signs to
> generate a "traditional" Income Statement and Balance Sheet?

There are indeed two different aspects here that have been conflated in
this thread.

One is what Beancount internally uses --- and I'm pretty sure that's not
gonna change.

One is how Fava shows (or not) signs to users. I agree it would make a
sense to have a UI option in Fava that make signs more "standard" and
less puzzling for traditional debit/credit double-entry accounting
users. This is a question for the Fava devs though, that usually react
quickly to this kind of suggestions via the GitHub issue tracker
https://github.com/beancount/fava

Cheers
--
Stefano Zacchiroli . za...@upsilon.cc . upsilon.cc/zack . . o . . . o . o
Computer Science Professor . CTO Software Heritage . . . . . o . . . o o
Former Debian Project Leader & OSI Board Director . . . o o o . . . o .
« the first rule of tautology club is the first rule of tautology club »

Zhuoyun Wei

unread,
May 9, 2019, 5:28:55 AM5/9/19
to Stefano Zacchiroli, Beancount
https://github.com/beancount/fava/issues/920

--
Zhuoyun Wei
> --
> 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+...@googlegroups.com.
> To post to this group, send email to bean...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beancount/20190509091837.ut5jm6vm2gelcev3%40upsilon.cc.

francois PEGORY

unread,
May 9, 2019, 5:37:43 AM5/9/19
to Beancount
Showing the sign on the traditional way meaning positive for income and negative for expenses could also have some consequences.

For example: I see the transactions related to my banking account. 
Here when I have a transaction where it is a expense, it is logical that the legs of the transaction related to my banking account is shown as negative (because it is shown like on my banking )but if E want to show the legs of the transaction also related to the "expense category" as negative I will finish to SHOW both of the legs as negative. 
Does it could be quite weird ? 

Regards

--
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+...@googlegroups.com.
To post to this group, send email to bean...@googlegroups.com.

John Mee

unread,
May 9, 2019, 6:32:54 PM5/9/19
to Beancount

You may want to read this introduction to find out why income, equity
and liabilities are negative in beancount:
https://docs.google.com/document/d/100tGcA4blh6KSXPRGCZpUlyxaRUwFHEvnz_k9DyZFn4/edit

Thanks Martin.  It's reassuring to discover that this 'fault' is by design.  What's even better is the discovery that I've actually done it "right"... my Incomes are indeed negative values as it stands.  So nothing to do here, glad I asked.

Whilst reading I discovered this...

We just use additions everywhere and learn to keep in mind that Liabilities, Equity and Income accounts normally have a negative balance. While this is unconventional, it’s much easier to grok. And If there is a need to view a conventional report with positive numbers only, we will be able to trigger that in reporting code (4), inverting the signs just to render them in the output.

(4)
This is not provided yet in Beancount, but would be trivial to implement. All we'd need to do is invert the signs of balances from Liabilities, Income and Equity accounts. It's on the roadmap to provide this eventually.

 
Is it really?  On a roadmap? Trivial to implement?

Martin Blais

unread,
May 9, 2019, 8:28:59 PM5/9/19
to Beancount
Two old ideas which have never been implemented:

- Allow all positive signs in the input, inverting based on the accounts (all postings are associated with accounts, so this would be easy).
This may make it a little more difficult to eyeball that a transaction balances properly, but that's up to the user in the end (it should be an option).

- Render all numbers in reports with inverted signs based on the accounts (balances are almost always associated with accounts, so this should also be easy).

We never bothered to implement either - it's rarely requested - and so far input and output are using the internal representation and users are just used to it.
I think those two features would be nice to have though, and provide a bit of polish on the interface of Beancount.









--
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+...@googlegroups.com.
To post to this group, send email to bean...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages