Statistical difference between a number of matrices.
11 次查看(过去 30 天)
显示 更早的评论
Hey,
I am trying to find a statistical approach to comparing the differences between matrices in a 3D matrix. I have a 3D matrix of m,n,z and I would like to look have a statistical measure (ideally a m,n matrix) that shows where the matrices most differ or are statistically different from their mean value.
I have come across a few tests from the statistical tool box that do this between two matrices, or even between 2 3D matrices, but I am not sure how to apply it to one 3D matrix. Perhaps a t-test (normalized by the mean) along the z axis that produces a mxn matrix of p-values would work here.
Hope my question makes sense.
0 个评论
采纳的回答
Star Strider
2016-5-31
If I understand correctly what you want to do, I would reshape it so that the entries along the third dimension of your original matrix are the columns of your reshaped matrix. Then choose a test (I’m using anova1 here), then use the multcompare function.
Example:
M = randi(9, 3, 4, 3) % Create Data
Mr = reshape(M, [], 3)' % Reshape (Obviously)
[p, t, stats] = anova1(Mr); % Create ‘stats’ Structure
[c,m,h,nms] = multcompare(stats); % Do Multiple Comparisons
There are likely a number of different approaches you can take. This is the one I consider most appropriate.
6 个评论
Star Strider
2016-6-1
编辑:Star Strider
2016-6-3
As always, my pleasure!
EDIT — (2016 06 03 at 18:00 UCT)
I thought about this a bit more, and came up with the idea of taking the confidence limits of the slope for each regression and multiplying them together to create a new sort of variable. The non-significant ones will be large and negative, and the highly significant ones will likely be large and positive, with the others in between. I’ve not tested this idea, but it — or something like it — might be worth considering.
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!