Model DMM7510 7½ Digit Graphical Sampling Multimeter Reference Manual
Section 8: TSP command reference
DMM7510-901-01 Rev. B / May 2015
8-17
Details
This function returns a table with statistical data about the data that was placed in the reading buffer.
The instrument automatically updates reading buffer statistics as data is added to the reading buffer.
When the reading buffer is configured to fill continuously and overwrite older data with new data, the
buffer statistics include the data that was overwritten. To get statistics that do not include data that
has been overwritten, define a large buffer size that will accommodate the number of readings you
will make.
The table returned from this function provides statistics at the time the function is called. Although the
instrument continues to update the statistics, the table that is returned is not updated. To get fresh
statistics, call this function again.
The
statsVar
parameter contains the values described in the following table.
Attribute
When returned
Description
min
n
> 0
A table that contains data about the minimum reading value that was added
to the buffer
mean
n
> 0
The average of all readings added to the buffer
stddev
n
> 1
The standard deviation of all readings that were added to the buffer
n
Always
The number of data points on which the statistics are based
max
n
> 0
A table that contains data about the maximum reading value that was added
to the buffer
If
n
equals zero (0), all other values are
nil
. If
n
equals 1,
stddev
is
nil
because the standard
deviation of a sample size of 1 is undefined.
Use the following command to get
statsVar
; a table with the following entries in it: n, min, max,
mean, and stddev.
statsVar = buffer.getstats(
bufferVar
)
Use the following commands to print these entries:
print(
statsVar
.n)
print(
statsVar
.mean)
print(
statsVar
.stddev)
print(
statsVar
.min.reading)
print(
statsVar
.min.timestamp)
print(
statsVar
.min.seconds)
print(
statsVar
.min.fractionalseconds)
print(
statsVar
.max.reading)
print(
statsVar
.max.seconds)
print(
statsVar
.max.fractionalseconds)
print(
statsVar
.max.timestamp)
The commands that return minimum and maximum values each also return tables. These tables
contain the following values:
Attribute
Description
reading
The reading value
timestamp
The
min.timestamp
is the timestamp of the minimum data point in the
buffer and the
max.timestamp
is the timestamp of the maximum data
point in the buffer