Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X
Hello all,
I have a matrix of vectors. I plotted one of the vectors below.
Can someone tell me the "proper" or most elegant way of calculating the mean of the values?
I have a mild flu and it's hard for me to concentrate, so I thought someone could nudge me along
TIA
Its not absolutely clear to me which mean of which values you are looking for.
Maybe you can setup a simplified sheet and post it here and tell us the desired result.
Here are a few possibilities:
I have a 1x7 matrix of 10x1 matrices. (below)
I'd like the mean of say, the 5th element (cue Mila Jovovich ) of the 10-element matrices.
This should do what you want, and possibly more:
Success!
Luc
Sorry, still not sure
Jason Cuadra wrote:
I have a 1x7 matrix of 10x1 matrices. (below)
I'd like the mean of say, the 5th element (cue Mila Jovovich ) of the 10-element matrices.
Does this mean that you want to get the mean of the fith 10 x 1 vector or would you like the mean of the seven values which are at the 5th position of each 10 x 1 matrix.
The first would be easy by just using mean(data[0,5).
I want the mean of the seven values which are at the 5th position of each 10 x 1 matrix.
Jason Cuadra wrote:
I want the mean of the seven values which are at the 5th position of each 10 x 1 matrix.
So I guess you already have the solution - see below 😉
Here are some ways to calculate the one or the other mean value:
OK guys, it seems that there isn't a one-liner way to do what I need; a procedure needs to be written.
Thanks ll