About data tables

A data table is essentially a file that resides in data logger memory (for information on data table storage. See Data memory. The file consists of five or more rows. Each row consists of columns, or fields. The first four rows constitute the file header. Subsequent rows contain data records. Data tables may store individual measurements, individual calculated values, or summary data such as averages, maximums, or minimums.

Typically, files are written to based on time or event. The number of data tables is limited to 250, which includes the Public, Status, DataTableInfo, and ConstTable. You can retrieve data based on a schedule or by manually choosing to collect data using data logger support software. See Collecting data.

Example data

TOA5, MyStation, CR1000X, 1142, CR1000X.Std.01, CPU:MyTemperature.CR1X, 1958, OneMin
TIMESTAMP RECORD BattV_Avg PTemp_C_Avg Temp_C_Avg

TS

RN

Volts

Deg C

Deg C

 

 

Avg

Avg

Avg

2019-03-08 14:24:00 0 13.68 21.84 20.71
2019-03-08 14:25:00 1 13.65 21.84 20.63
2019-03-08 14:26:00 2 13.66 21.84 20.63
2019-03-08 14:27:00 3 13.58 21.85 20.62
2019-03-08 14:28:00 4 13.64 21.85 20.52
2019-03-08 14:29:00 5 13.65 21.85 20.64

Table definitions

Each data table is associated with descriptive information, referred to as a“table definition,” that becomes part of the file header (first few lines of the file) when data is downloaded to a computer. Table definitions include the data logger type and ClosedOS The operating system (also known as "firmware") is a set of instructions that controls the basic functions of the data logger and enables the use of user written CRBasic programs. The operating system is preloaded into the data logger at the factory but can be re-loaded or upgraded by you using Device Configuration Utility software. The most recent data logger operating system .obj file is available at www.campbellsci.com/downloads. version, name of the CRBasic program associated with the data, name of the data table (limited to 20 characters), and alphanumeric field names.

Header rows

The first header row of the data table is the environment line, which consists of eight fields. The following list describes the fields using the previous table entries as an example:

The second header row reports field names. Default field names are a combination of the variable names (or Closedalias A second name assigned to variable in CRBasic.es) from which data is derived, and a three-letter suffix. The suffix is an abbreviation of the data process that outputs the data to storage. A list of these abbreviations follows in Data processing abbreviations.

If a field is an element of an Closedarray A group of variables as declared in CRBasic., the field name will be followed by a indices within parentheses that identify the element in the array. For example, a variable named Values, which is declared as a two-by-two array in the data logger program, will be represented by four field names: Values(1,1), Values(1,2), Values(2,1), and Values(2,2). There will be one value in the second header row for each scalar value defined by the table.

If the default field names are not acceptable to the programmer, the FieldNames() instruction can be used in the ClosedCRBasic Campbell Scientific's BASIC-like programming language that supports analog and digital measurements, data processing and analysis routines, hardware control, and many communications protocols. program to customize the names. TIMESTAMP, RECORD, BattV_Avg, PTemp_C_Avg, and Temp_C_Avg are the default field names in the previous Example data.

The third header row identifies engineering units for that field. These units are declared at the beginning of a ClosedCRBasic Campbell Scientific's BASIC-like programming language that supports analog and digital measurements, data processing and analysis routines, hardware control, and many communications protocols. program using the optional Units() declaration. In ClosedShort Cut A CRBasic programming wizard suitable for many data logger applications. Knowledge of CRBasic is not required to use Short Cut., units are chosen when sensors or measurements are added. Units are strictly for documentation. The data logger does not make use of declared units, nor does it check their accuracy.

The fourth header row reports abbreviations of the data process used to produce the field of data.

Data processing abbreviations

Data processing name Abbreviation
Totalize Tot
Average Avg
Maximum Max
Minimum Min
Sample at Max or Min SMM
Standard Deviation Std
Moment MMT
Sample No abbreviation
Histogram1 Hst
Histogram4D H4D
FFT FFT
Covariance Cov
Level Crossing LCr
WindVector WVc
Median Med
ET ETsz
Solar Radiation (from ET) RSo
Time of Max TMx
Time of Min TMn

Data records

Subsequent rows are called data records. They include observed data and associated record keeping. The first field is a time stamp (TS), and the second field is the record number (RN).

The time stamp shown represents the time at the beginning of the scan in which the data is written. Therefore, in record number 3 in the previous Example data, Temp_C_Avg shows the average of the measurements taken over the minute beginning at 14:26:01 and ending at 14:27:00. As another example, consider rainfall measured every second with a daily total rainfall recorded in a data table written at midnight. The record time stamped 2019-03-08 00:00:00 will contain the total rainfall beginning at 2019-03-07 00:00:01 and ending at 2019-03-08 00:00:00.

NOTE:

TableName.Timestamp syntax can be used to return the timestamp of a data table record, expressed either as a time into an interval (for example seconds since 1970 or seconds since 1990) or as a date/time string. For more information, see: https://www.campbellsci.com/blog/programmatically-access-stored-data-values .