Dear users,
Does anyone know whether it is possible to calculate a weighted geometric mean in excel?
Any help with this would be much appreciated!
/hs
Dear users,
Does anyone know whether it is possible to calculate a weighted geometric mean in excel?
Any help with this would be much appreciated!
/hs
Hi -
Shouldn't be too difficult. You would need a column for your observations (say column X), a column for your weights (say column W), and a column to multiply W*ln(X) (Let's call this column Y).
Basically, the formula would be:
=exp((sum(Y1:Yn)/sum(W1:Wn)) where n is the number of observations. For example if you had 5 observations and 5 weights the formula would be =exp((sum(Y1:Y5)/sum(W1:W5))
Hope this helps.
Hi there, thanks a lot for this reply, that is very kind of you!
What I was thinking is that there might be a way to skip the middle step calculating column Y? Kind of along the same line as the Sumproduct-funtion. I have approx. 40 40x40 matrices for which I have to do it, so any reduction of middle steps would save me a lot of time:-)
In any event thanks a lot for your help!
/hs
using loginjmor's example you could use this formula which follows his method but doesn't need a helper column
=EXP(SUMPRODUCT(W1:W5,LN(X1:X5))/SUM(W1:W5))
or use this "array formula"
=PRODUCT(X1:X5^(W1:W5/SUM(W1:W5)))
confirmed with CTRL+SHIFT+ENTER
in both cases the ranges need to be fully populated (no blanks) - they should give the same results
Audere est facere
Thanks a lot to both of you that is perfect!
All the best
Hi,
What do I have to put in the "weight" column? Numbers from 1 (most important) to 5 (less important) or percentages?
Administrative Note:
Welcome to the forum.
We are happy to help, however whilst you feel your request is similar to this thread, experience has shown that things soon get confusing when answers refer to particular cells/ranges/sheets which are unique to your post and not relevant to the original.
Please see Forum Rule #4 about hijacking and start a new thread for your query.
If you are not familiar with how to start a new thread see the FAQ: How to start a new thread
Ali
Enthusiastic self-taught user of MS Excel who's always learning!
Don't forget to say "thank you" in your thread to anyone who has offered you help.
You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.
Forum Rules (updated August 2023): please read them here.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks