Download Help (Windows Only) |
Owning Class: statistics
Requires: MathScript RT Module
histogram(x)
histogram(x, c)
histogram(x, m)
n = histogram(x, c)
[n, ctr] = histogram(x)
[n, ctr] = histogram(x, m)
Legacy Name: hist
Counts the number of values that fall in specified intervals. If you do not request an output, LabVIEW returns a histogram plot.
Name | Description |
---|---|
x | Specifies the data values. x is a matrix. |
c | Specifies the centers of all intervals in which you want to divide the range of x. c is a matrix. The elements in c must be in ascending order. |
m | Specifies the number of equally spaced intervals in which to divide the range of x. m is a positive integer. The default is 10. |
Name | Description |
---|---|
n | Returns the number of elements that fall in each interval. n is an array of integers. |
ctr | Returns the centers of all intervals if you do not specify c. ctr is an array. |
The following table lists the support characteristics of this function.
Supported in the LabVIEW Run-Time Engine | Yes (if you request output) |
Supported on RT targets | Yes (if you request output) |
Suitable for bounded execution times on RT | Not characterized |
[N, C] = histogram(rand(1, 100), 20)
[N, C] = histogram(rand(1, 100))
N = histogram(rand(1, 100), 0:0.1:1)