14: TSP command reference 2470 High Voltage SourceMeter Instrument
14-10 2470-901-01 Rev. A / May 2019
buffer.getstats()
This function returns statistics from a specified reading buffer.
Type TSP-Link accessible
Affected by Where saved Default value
Usage
statsVar = buffer.getstats()
statsVar = buffer.getstats(bufferVar)
statsVar = buffer.getstats(bufferVar, absStartTime, absStartFractional, absEndTime,
absEndFractional)
statsVar = buffer.getstats(bufferVar, relStartTime, relEndTime)
A table that contains the entries for buffer statistics; see Details for information
on the entries
The name of the reading buffer, which may be a default buffer (defbuffer1 or
defbuffer2) or a user-defined buffer; if no buffer is specified, this parameter
defaults to
An integer that represents the absolute start time in seconds
An integer that represents the portion of the absolute start time that is in
fractional seconds
An integer that represents the absolute end time in seconds
An integer that represents the portion of the absolute end time that is in
fractional seconds
The start time in seconds relative to the start time of the data in the buffer
The end time in seconds relative to the start time of the data in the buffer
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 old 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.