Reputation: 48916
I got the following results after applying:[h,bins]=hist(data)
, such that, the data
will contain the LBP (Local Binary Pattern)
values.
h =
221 20 6 4 1 1 2 0 0 1
bins =
Columns 1 through 7
8.2500 24.7500 41.2500 57.7500 74.2500 90.7500 107.2500
Columns 8 through 10
123.7500 140.2500 156.7500
I want to ask the following:
Does the first bin
represent the values 0-8.25
and the second bin
the values 8.26-24.75
, and so forth?
For the h
value 221
, does it mean that we have computed 221
an LBP
value ranging from 0-8.25
?
Upvotes: 0
Views: 719
Reputation: 26069
1) No. The bin location is in the center value of the bin, that is, for the first bin the values are 0-16.5
, the second bin is 16.5-33
, etc. Use histc
if it is more natural to specify bin edges instead of centers.
2) h(1)=221
means that from your entire data
set (that has 256 elements according to your question), 221 elements had values ranging between 0-16.5
.
Upvotes: 1