Histogram normalisation: a question about terminology

3 vues (au cours des 30 derniers jours)
Sim
Sim le 14 Juil 2023
Commenté : Sim le 1 Août 2023
Let's consider the histogram and histcounts functions, as in these two cases:
num_bins = 30; % <-- note: I specify the "number of bins" and not the "bin width", which can be different from 1
% Case 1
histcounts(X,num_bins,'Normalization','probability');
histogram(X,'NumBins',num_bins,'Normalization','probability');
% Case 2
histcounts(X,num_bins,'Normalization','pdf');
histogram(X,'NumBins',num_bins,'Normalization','pdf');
Do I understand correctly that
  1. For Case 1, I get the "Relative Frequency Histogram" or an "empirical estimate of the Probability Mass Function"?
  2. For Case 2, - where I divide by the bin widths as well -, I get the an "empirical estimate of the Probability Density Function"?

Réponses (1)

Satwik Samayamantry
Satwik Samayamantry le 14 Juil 2023
Hi Sim,
Yeah you got it right. Your understanding for both cases is correct.
  3 commentaires
Steven Lord
Steven Lord le 1 Août 2023
See the description of the Normalization name-value argument on either of the histogram or histcounts documentation pages. It describes exactly what the Values property of the histogram or the first output of the histcounts function represent.
Sim
Sim le 1 Août 2023
thanks @Steven Lord :-)

Connectez-vous pour commenter.

Catégories

En savoir plus sur Data Distribution Plots dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by