weighted average in Balance Sheet (was: Re: Stock Sales - Balance sheet unbalanced)

Christian Stimming stimming at tuhh.de
Mon Jan 24 04:35:01 EST 2005


Derek Atkins schrieb:
>>I usually use the "Nearest in Time" option;  the weighted average is not 
>>particularly informative.  Weighted average is, however, the default; 
>>and it appears that that it's used to determine the cost when computing 
>>the unrealized gain.  Since it's calculated using absolute values, it's 
>>not even the correct number.
> 
> Hmm, then that's definitely a bug..

However, there is a particular reason to have "Weighted Average" the 
default for any of the multi-currency report: GnuCash has two kinds of 
prices. There are *explicit* prices with an entry in the Price Editor. 
And there are *implicit* prices whenever a transaction with multiple 
currencies is booked.

Users with stock accounts probably have all their prices entered into 
the price editor as explicit prices. However, users with no stocks but 
rather some foreign currencies usually have no prices in the price 
database but have all prices/exchange rates only as implicit prices in 
their currency exchange transactions. If those users open any of the 
multi-currency reports and the default is one of the explicit-price 
options (nearest/latest in time) as opposed to the implicit-price option 
(weighted average), then these users will surprisingly observe that 
their foreign currency exchange rate is unknown, i.e. zero. This is 
usually very surprising for the users ("Where are my foreign currencies? 
Who said gnucash is supporting multi-currencies?"). Therefore the 
decision was at that time to make "Weighted Average" the price default, 
because that guarantees at least the availability of any non-zero 
price/exchange rate. (In engineer-speak: On average, this option will 
give a better approximation to the desired balance sheet result than any 
other option.)

Unfortunately, the downside of that decision is the behaviour you've 
just observed: For stock accounts, the price obtained from the "weighted 
average" is probably plain wrong or at least unintended by the user. If 
anyone can come up with a suggestion on how to change the default 
multi-currency setting *and* still prevent the shock for the 
implicit-price-users of seeing all their balances at zero not knowing 
what's wrong -- then of course we should implement that suggestion. But 
simply changing the average will only cause a different problem to show up.

Christian



More information about the gnucash-devel mailing list