calculating the mean

1 回表示 (過去 30 日間)
kash
kash 2012 年 2 月 5 日
編集済み: Jan 2013 年 9 月 30 日
i used the code
out = [CLL_combinations(:,1:2,:) mean(CLL_combinations(:,3:end,:),2)]
i get output as
CLL_MEAN(:,:,1) =
83.0000 83.0000 0.6598
87.0000 87.0000 0.2103
;
;
;
CLL_MEAN(:,:,50) =
90.0000 90.0000 -0.1558
96.0000 96.0000 0.3872
now i want to find the mean of 3rd column of
CLL_MEAN(:,:,1) =
83.0000 83.0000 0.6598
87.0000 87.0000 0.2103
;
;
;
CLL_MEAN(:,:,50) =
90.0000 90.0000 -0.1558
96.0000 96.0000 0.3872
so finally i should get 50 means values,and output must be displayes aS
CLL_MEAN_NEW=
0.4099
;
;
0.1157
PLEASE HELP
  1 件のコメント
Image Analyst
Image Analyst 2012 年 2 月 5 日
Note: You only need to highlight the actual code, not non-code explanations. There also has to be a blank line in between your explanations and where the code starts.

サインインしてコメントする。

採用された回答

Andrei Bobrov
Andrei Bobrov 2012 年 2 月 5 日
CLL_MEAN_NEW = permute(mean(CLL_MEAN(:,end,:)),[3 2 1])
OR
CLL_MEAN_NEW = squeeze(mean(CLL_MEAN(:,end,:)))
  1 件のコメント
kash
kash 2012 年 2 月 6 日
Thanks andre1

サインインしてコメントする。

その他の回答 (1 件)

Junaid
Junaid 2012 年 2 月 5 日
Hi,
could you please reformat the code. As it is difficult to see code. whenever you have line other then code then make that bold and don't put in the code section.
for example:
first i make an array
a = [1:10];
then I plot it.
plot(a);

カテゴリ

Help Center および File ExchangeMATLAB についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by