HOW TO EDIT A trace.ctl FILE The trace.ctl file contains a series of header records followed by one or more records containing search conditions. The following documen- tation describes what this information is. CAUTION: Although a successful search for data may require that a change only be made on the header record of the first search condition for a trace, nevertheless the change should be made in ALL of the search condition header records for that trace so as not to confuse the plotting program. The header record consists of eight integers: Position Meaning 1 Trace number for this condition (ITRC) 2 Search parameter identification (IDDFLD) 3 The variable type (IVRTYP) 4 The data combination code (ICMTYP) 5 Number of conditions following the header (NCN) 6 Plot number to which trace belongs (IDPLT) 7 Plot type (not used in searching) 8 Data consistency checking code sequence: KMCH/KASE/KPADZ/KLTP The records following the header record contain the conditions. Each record begins with an integer which gives the data checking code or comparison code (ICNTYP). See Table 2 below for the meanings of ICNTYP. Each condition record also contains either one or two real values or one or two character values. These values define either a range of values or a single value to be matched exactly. ICNTYP tells the code how the values are to be used. This documentation block from the search condition setting subroutine explains more about how these numbers are used: C************************************************************************ SUBROUTINE SRCH_SET ( itrc, kmch, kase, kpadz, kltp, + idplt, iddfld, icntyp, + ivrtyp, icmtyp, charcn, realcn, ncn, + iret ) C************************************************************************ C* SRCH_SET * C* * C* This subroutine sets a single search condition for a single trace. * C* * C* KMCH triggers consistent data combination. KMCH has the following * C* meaning for non-time series searches: * C* * C* KMCH value Meaning * C* * C* 0 No consistency checking * C* 1 Data counts will be identical at corresponding * C* points (inter or intra trace, accordingly) * C* 2 Verification times and counts will be identical * C* at corresponding points * C* * C* When KMCH is not 0, points with the most frequently occurring data * C* count will constitute the trace. * C* * C* For time series searches, KMCH has the following meaning: * C* * C* KMCH value Meaning * C* * C* 0 No consistency checking * C* 1 Inter and/or intra trace counts are consistent * C* 2 Points not found in ALL traces are eliminated * C* * C* Traces idenitified to be on the same plot will be made consistent * C* in accordance with the KMCH value. Once KMCH is set for a trace, * C* subsequent values of KMCH are ignored. The value of KMCH set for * C* the first trace of several having the same IDPLT operates for all * C* of them. * C* * C* KASE specifies how the consistency checking associated with the * C* KMCH value is applied. KASE has the following meaning: * C* * C* KASE value Meaning * C* * C* 0 Automatically determined * C* 1 Intra trace consistency (varying trace to trace) * C* 2 Inter trace consistency (varying point to point) * C* 3 Total consistency (along and through the traces) * C* * C* Like KMCH, once KASE is set for a trace, subsequent values of KASE * C* are ignored. The value of KASE set for the first trace of several * C* having the same IDPLT operates for all of them. * C* * C* KPADZ is provided to allow records with all zero FHO values to be * C* absent in the input VSDB data file. These values will be padded in * C* if KPADZ > 0. Padding takes place only when the independent * C* variable is threshold. * C* * C* KLTP is a value ranging from 0 to 99 that gives the percentage of * C* data loss allowed before relaxation of the data combination con- * C* sistency checking specified by KMCH. For example, if KLTP = 66, * C* then up to 66% of data can be lost and data consistency checking * C* will remain in force. If KLTP = 10, only 10% of data can be lost * C* with consistency checking in force---if consistency checks would * C* eliminate more than 10% of data the consistency requirements are * C* removed. This percentage is applied to each trace. If any one * C* trace fails the criterion, consistency checking is lifted. KLTP * C* is used only when KASE = 0. * C* * C* Once KMCH, KASE, KPADZ, and KLTP are set for a trace, subsequent * C* values are ignored; only the first setting is used. * C* * C* IDPLT is an arbitrary positive integer used to mark this trace as * C* belonging to a particular plot. When the data is combined, all * C* traces with the same value of IDPLT must have the same number and * C* times of contributions at corresponding points. Once IDPLT is set * C* for a trace, subsequent values of IDPLT in calls to SRCH_SET for * C* the same trace are ignored. * C* * C* This search criterion applies to the descriptor data whose element * C* number in TABLE 1 below matches the value in IDDFLD. If IDDFLD is * C* greater than 100, the condition applies to a data value. During a * C* search, if the number of data values (including the count) exceeds * C* MXDPTH, then only the values for which there exists a dependent * C* variable condition will be stored in the array DTRACE. The array * C* KINDEX in COMMON records the data indexes actually stored in DTRACE. * C* If the data index is 1, that is the count data field. * C* * C* TABLE 1. * C* * C* Element Data Field Description Data type Desc Field * C* * C* 1 Version number CHAR 1 * C* 2 Model being verified CHAR 2 * C* 3 Forecast hour REAL 3 * C* 4 Forecast time window REAL 3 * C* 5 Verification YYYYMMDDHHNN CHAR 4 * C* 6 Verifying time window REAL 4 * C* 7 Time increment for data REAL 4 * C* 8 Verifying analysis CHAR 5 * C* 9 Verifying region CHAR 6 * C* 10 Statistic type identifier CHAR 7 * C* 11 Threshold for data REAL 7 * C* 12 Parameter name CHAR 8 * C* 13 Level identifier CHAR 9 * C* 14 Level value REAL 9 * C* 15 Verifying HHNN CHAR 5 * C* 16 Time period for combination CHAR 4 * C* 101 Count value REAL - * C* 102 + ... Statistic values REAL - * C* * C* * C* The type of conditional check is determined by ICNTYP. TABLE 2 * C* below gives the search type associated with the possible values * C* for ICNTYP: * C* * C* TABLE 2. * C* * C* ICNTYP Meaning * C* * C* 0 Wild card -- no checks * C* 1 Real check for x < REALCN (1,*) * C* 2 Real check for x <= REALCN (1,*) * C* 3 Real check for x > REALCN (1,*) * C* 4 Real check for x >= REALCN (1,*) * C* 5 Real check for REALCN (1,*) < x < REALCN (2,*) * C* 6 Real check for REALCN (1,*) <= x <= REALCN (2,*) * C* 7 Real check for REALCN (1,*) < x <= REALCN (2,*) * C* 8 Real check for REALCN (1,*) <= x < REALCN (2,*) * C* 9 Real check for elements in the list REALCN (1,NCN) * C* 10 Char check for c < CHARCN (1,*) * C* 11 Char check for c <= CHARCN (1,*) * C* 12 Char check for c > CHARCN (1,*) * C* 13 Char check for c >= CHARCN (1,*) * C* 14 Char check CHARCN (1,*) < c < CHARCN (2,*) * C* 15 Char check CHARCN (1,*) <= c <= CHARCN (2,*) * C* 16 Char check CHARCN (1,*) < c <= CHARCN (2,*) * C* 17 Char check CHARCN (1,*) <= c < CHARCN (2,*) * C* 18 Char check for elements in the list CHARCN (1,NCN) * C* 19 Time period check for finding existing period averages * C* 20 Time period check for making period averages * C* * C* where x is some real value, and c is some character string. * C* * C* Only independent variables can have more than one pair of comparison * C* values and, hence, more than one value of ICNTYP. Dependent * C* variable listed values are always in position (1,i), where i ranges * C* from 1 to NCN, the number in the list. * C* * C* If a character type check is indicated for a data descriptor that * C* is type REAL in TABLE 1, then the check will be made against the * C* entire character header field associated with the data descriptor. * C* Note that verification time checking (IDDFLD = 5) is always of * C* type character. * C* * C* Time period checks are be specified as a string of one or more of * C* a set of single-character time period designators (P). These * C* designators are interpreted using the values in elements 5 and 6 * C* of TABLE 1. TABLE 3 below relates each single character period * C* designator (P) to the value in element 6 and the string value in * C* the indicated segment of element 5 required for a search match when * C* ICNTYP = 19. If ICNTYP = 20, the date is checked for the time range * C* corresponding to the designator. If it is within the time window * C* the data is used. * C* * C* TABLE 3. * C* * C* P Meaning Element 6 Element 5 Segment Element 5 Segment Value * C* * C* D Daily 24 HHNN 1200 * C* M Monthly 730 DDHHNN 150000 * C* 1 1st qrtr 2190 MMDDHHNN 02150000 * C* 2 2nd qrtr 2190 MMDDHHNN 05150000 * C* 3 3rd qrtr 2190 MMDDHHNN 08150000 * C* 4 4th qrtr 2190 MMDDHHNN 11150000 * C* A 1st half 4380 MMDDHHNN 04010000 * C* B 2nd half 4380 MMDDHHNN 10010000 * C* Y year 8760 MMDDHHNN 07010000 * C* W winter 2190 MMDDHHNN 01150000 * C* V spring 2190 MMDDHHNN 04150000 * C* S summer 2190 MMDDHHNN 07150000 * C* F fall 2190 MMDDHHNN 10150000 * C* * C* More than one P designator may be entered, which has the effect of * C* a list---the condition is satisfied if any one of the P designators * C* is satisfied. * C* * C* If the condition applies to control how values will be accumulated * C* to appear as a function of some other set of contitions, then the * C* condition is for a dependent variable. If the condition discrimi- * C* nates among the various points along a trace, then that condition is * C* for the independent variable. IVRTYP is set according to TABLE 4. * C* * C* TABLE 4. * C* * C* IVRTYP Meaning * C* * C* 0 -> condition applies to a dependent variable * C* 1 -> condition applies to an independent variable * C* * C* ICNTYP = 0 may be useful for either an independent variable or a * C* dependent variable. For example, for a time series, all verifying * C* times may be desired with verifying time as the independent variable.* C* In this case, ICNTYP = 0 for verifying time. In the case of a * C* dependent variable, ICNTYP = 0 for conditions that are only being * C* used to indicate the data position. This is particularly useful * C* when the search records have more than MXDPTH number of data values. * C* * C* There are different ways in which the data can be combined. The * C* method of combination is specified in ICMTYP. TABLE 5 gives the * C* possible values and meanings of ICMTYP: * C* * C* TABLE 5. * C* * C* ICMTYP Meaning * C* * C* 0 -> No combination * C* 1 -> Averaging by summing counts and partial sums * C* 2 -> Sum data counts and the count-value products * C* (i.e., values are multiplied by the count) * C* * C* Once ICMTYP is set for a trace, it cannot be changed. Although * C* SRCH_SET must be called at least once, and perhaps many times more * C* for a given trace, the value of ICMTYP passed in the first call * C* is used, the rest are ignored. * C* * C* SRCH_INI should be called before beginning a new set of calls to * C* to SRCH_SET. SRCH_INI erases all previous search settings. * C* * C* SRCH_SET ( ITRC, KMCH, KASE, KPADZ, KLTP, IDPLT, IDDFLD, ICNTYP, * C* IVRTYP, ICMTYP, CHARCN, REALCN, NCN, IRET ) * C* * C* Input parameters: * C* ITRC INTEGER Number of trace * C* KMCH INTEGER Code for consistent combination * C* KASE INTEGER Consistency application method * C* KPADZ INTEGER Flag for zero padding operation * C* KLTP INTEGER Data loss tolerance percentage * C* IDPLT INTEGER Plot identifier for this trace * C* IDDFLD INTEGER Search data element number * C* ICNTYP (NCN) INTEGER Type of condition * C* IVRTYP INTEGER Type of variable * C* ICMTYP INTEGER Method of data combination * C* CHARCN (2,NCN) CHAR* List/bounds for char condition * C* REALCN (2,NCN) REAL List/bounds for real condition * C* NCN INTEGER # in list or # of comp pairs * C* * C* Output parameters: * C* IRET INTEGER Return code * C** * C************************************************************************