Generate Weighted Histogram

버전 1.0.0.0 (3.79 KB) 작성자: Mehmet Suzen
histwc is a simple utility to construct weighted histogram.
다운로드 수: 3.1K
업데이트 날짜: 2013/7/8

라이선스 보기

histwc is a utility to construct weighted histogram. Given
number of bins, values and corresponding weights, there are
two functions produces identical outputs: a vector of histogram
frequencies and intervals. Functions generate a vector of
cumulative weights for data histogram. Equal number of bins
will be considered using minimum and maximum values of the data.
Weights will be summed in the given bin. These two vectors can
be used to plot the weighted histogram. One of the function is
vectorized, but not necessarily faster.

Example:
%vv = [1.0 1.0 2.0 5.0 3.0 4.0 1.0 5.0 3.0 1.0]; % values
%ww = [0.1 0.1 0.05 0.05 0.2 0.05 0.05 0.1 0.1 0.2]; % weights
%nbins = 5;
%[histw, intervals] = histwc(vv, ww, nbins);
% Example Visualise:
% bar(intervals, histw)

인용 양식

Mehmet Suzen (2024). Generate Weighted Histogram (https://www.mathworks.com/matlabcentral/fileexchange/42493-generate-weighted-histogram), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2012a
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Histograms에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!
버전 게시됨 릴리스 정보
1.0.0.0