Average in interval histogram

2 次查看(过去 30 天)
Dani D
Dani D 2016-7-22
Hello, I want calculate mean of each interval . Suppose interval is equal.
  1 个评论
per isakson
per isakson 2016-7-22
Try
X = rand(100,1);
[N,edges,bin] = histcounts( X );
mean_of_forth_bin = mean( X(bin==4) )
outputs
mean_of_forth_bin =
0.7103

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Histograms 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by