<< Click to Display Table of Contents >>
## Stabilization Functions |

The Collect stabilization functions assess the stability of field parameter measurements (e.g., when purging a groundwater monitoring well prior to taking a sample). The functions perform calculations as data are entered in forms on the Collect Mobile app, to determine if a field parameter's values have stabilized according to the specified criteria. Such formulas set on a number of field parameters can combine to give an overall indication of stabilization.

These functions are typically used when the field parameters are recorded in a child form in the template. Adding a FILTER function is necessary to ensure that the stabilization functions are only checking parameter values for a related set of child form records (i.e., field parameters for a given parent sample record). All of these stabilization functions should use the FILTER function on the second parameter, which defines the value on which records are sorted. Each function described below includes an example (Example 2) of how to build the formula with this filtering in place.

All stability functions take a minimum of 4 parameters and can take up to 5 parameters. They all check the stability of the first parameter, using the second parameter as the sort criteria, the third parameter as the number of consecutive rows to check, the fourth parameter as a tolerance, and the optional fifth parameter as a Boolean indicating that all rows should be used in the check (defaults to FALSE). The only difference between each of these functions is the actual stabilization criteria, and therefore, the meaning of the tolerance. They return NULL if a NULL value is found in the final list of values to be checked for stability.

STABLEDIF

The STABLEDIF function checks that the difference between the two consecutive values is always less than the tolerance.

STABLEDIF(<Parameter_1>,<Parameter_2>,<NumericParameter_1>,<NumericParameter_2>,{<OptionalBooleanParameter_1>})

Aggregate = Yes

Example 1 – Collect Form Stability (no child forms)

In this formula example, both the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in the same form on the form template and is only working with one location. If working with more than one location, than there is a need to sort and filter the locations.

Date |
pH |
Temp |
Turb |
---|---|---|---|

2019/05/20 08:33:27 |
6.44 |
10.43 |
142 |

2019/05/20 08:36:18 |
5.12 |
9.47 |
134 |

2019/05/20 08:39:31 |
7.01 |
10.34 |
109 |

2019/05/20 08:42:55 |
8.13 |
10.07 |
122 |

2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

STABLEDIF([Stability.pH],[Stability.Date],3,0.2) = TRUE when evaluated on the last row.

STABLEDIF([Stability.pH],[Stability.Date],3,0.2) = FALSE when evaluated on other rows.

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for pH. This stability function is checking that the difference between each pair of consecutive pH values, within the last 3 records, is within a tolerance of 0.2 units. The formula returns TRUE because the difference between consecutive values for the last 3 rows is less than 0.2.

STABLEDIF([Stability.pH],[Stability.Date],4,0.2) = FALSE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for pH. This stability function is checking that the difference between each pair of consecutive pH values, within the last 4 records, is within a tolerance of 0.2 units. The formula returns FALSE because the difference between 7.02 and 9.34 is greater than 0.2.

Example 2 – Collect ParentForm Stability and ChildForm StabilityChild

In this formula example, the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in different forms on the form template (i.e., Parent-Child records). In this case, the parent form will contain the Well ID/Location information and the child form will contain the Field Parameters.

ParentForm – Stability

#id (Parent Form) |
Location (Form Records) |
---|---|

1023 |
Well ID 001 |

1038 |
Well ID 002 |

ChildForm – StabilityChild

#parent_#id |
#id (Child Form) |
Date |
pH |
Temp |
Turb |
---|---|---|---|---|---|

1023 |
1 |
2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

1023 |
2 |
2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

1023 |
3 |
2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

1023 |
4 |
2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

1038 |
5 |
2019/05/22 10:24:40 |
8.85 |
12.09 |
128 |

1038 |
6 |
2019/05/22 10:26:59 |
7.07 |
10.81 |
103 |

1038 |
7 |
2019/05/22 10:29:17 |
7.13 |
10.92 |
109 |

1038 |
8 |
2019/05/22 10:33:25 |
7.19 |
11.00 |
101 |

STABLEDIF([StabilityChild.pH],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[StabilityChild.Date]),3,0.2) = TRUE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for pH. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the difference between each pair of consecutive pH values, within the last 3 records, is within a tolerance of 0.2 units. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLEDIF([StabilityChild.pH],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),4,0.2) = FALSE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for pH. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the difference between each pair of consecutive pH values, within the last 4 records, is within a tolerance of 0.2 units. The formula returns FALSE as the stability has not been met based on the formula criteria.

STABLELE

The STABLELE function checks that all values to be checked are less than or equal to the tolerance specified in the fourth parameter.

STABLELE(<Parameter_1>,<Parameter_2>,<NumericParameter_1>,<NumericParameter_2>,{<OptionalBooleanParameter_1>})

Aggregate = Yes

Example 1 – Collect Form Stability (no child forms)

In this formula example, both the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in the same form on the form template and is only working with one location. If working with more than one location, than there is a need to sort and filter the locations.

Date |
pH |
Temp |
Turb |
---|---|---|---|

2019/05/20 08:33:27 |
6.44 |
10.43 |
142 |

2019/05/20 08:36:18 |
5.12 |
9.47 |
134 |

2019/05/20 08:39:31 |
7.01 |
10.34 |
109 |

2019/05/20 08:42:55 |
8.13 |
10.07 |
122 |

2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

STABLELE([Stability.Turb],[Stability.Date],3,110) = TRUE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for Turb. This stability function is checking that the value for Turb is equal to or less than a tolerance of 110 units. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLELE([Stability.Turb],[Stability.Date],4,110) = FALSE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for Turb. This stability function is checking that the value for Turb is equal to or less than a tolerance of 110 units. The formula returns FALSE as the stability has not been met based on the formula criteria.

Example 2 – Collect ParentForm Stability and ChildForm StabilityChild

In this formula example, the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in different forms on the form template (i.e., Parent-Child records). In this case, the parent form will contain the Well ID/Location information and the child form will contain the Field Parameters.

ParentForm – Stability

#id (Parent Form) |
Location (Form Records) |
---|---|

1023 |
Well ID 001 |

1038 |
Well ID 002 |

ChildForm – StabilityChild

#parent_#id |
#id (Child Form) |
Date |
pH |
Temp |
Turb |
---|---|---|---|---|---|

1023 |
1 |
2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

1023 |
2 |
2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

1023 |
3 |
2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

1023 |
4 |
2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

1038 |
5 |
2019/05/22 10:24:40 |
8.85 |
12.09 |
128 |

1038 |
6 |
2019/05/22 10:26:59 |
7.07 |
10.81 |
103 |

1038 |
7 |
2019/05/22 10:29:17 |
7.13 |
10.92 |
109 |

1038 |
8 |
2019/05/22 10:33:25 |
7.19 |
11.00 |
101 |

STABLELE([StabilityChild.Turb],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),3,110) = TRUE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for Turb. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the value for Turb is equal to or less than a tolerance of 110 units. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLELE([StabilityChild.Turb],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),4,110) = FALSE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for Turb. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the value for Turb is equal to or less than a tolerance of 110 units. The formula returns FALSE as the stability has not been met based on the formula criteria.

STABLEMAX

The STABLEMAX function checks that the difference between the largest and smallest value is within the tolerance specified in the fourth parameter.

STABLEMAX(<Parameter_1>,<Parameter_2>,<NumericParameter_1>,<NumericParameter_2>,{<OptionalBooleanParameter_1>})

Aggregate = Yes

Example 1 – Collect Form Stability (no child forms)

In this formula example, both the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in the same form on the form template and is only working with one location. If working with more than one location, than there is a need to sort and filter the locations.

Date |
pH |
Temp |
Turb |
---|---|---|---|

2019/05/20 08:33:27 |
6.44 |
10.43 |
142 |

2019/05/20 08:36:18 |
5.12 |
9.47 |
134 |

2019/05/20 08:39:31 |
7.01 |
10.34 |
109 |

2019/05/20 08:42:55 |
8.13 |
10.07 |
122 |

2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

STABLEMAX([Stability.pH],[Stability.Date],3,0.2) = TRUE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for pH. This stability function is checking that the maximum difference, between the largest and smallest pH values within the last 3 records, is within a tolerance of 0.2 units. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLEMAX([Stability.pH],[Stability.Date],4,0.2) = FALSE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for pH. This stability function is checking that the maximum difference, between the largest and smallest pH values within the last 4 records, is within a tolerance of 0.2 units. The formula returns FALSE as the stability has not been met based on the formula criteria.

Example 2 – Collect ParentForm Stability and ChildForm StabilityChild

In this formula example, the Well ID/Location information and Field Parameters (pH, temperature, etc.) are in different forms on the form template (i.e., Parent-Child records). In this case, the parent form will contain the Well ID/Location information and the child form will contain the Field Parameters.

ParentForm – Stability

#id (Parent Form) |
Location (Form Records) |
---|---|

1023 |
Well ID 001 |

1038 |
Well ID 002 |

ChildForm – StabilityChild

#parent_#id |
#id (Child Form) |
Date |
pH |
Temp |
Turb |
---|---|---|---|---|---|

1023 |
1 |
2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

1023 |
2 |
2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

1023 |
3 |
2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

1023 |
4 |
2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

1038 |
5 |
2019/05/22 10:24:40 |
8.85 |
12.09 |
128 |

1038 |
6 |
2019/05/22 10:26:59 |
7.07 |
10.81 |
103 |

1038 |
7 |
2019/05/22 10:29:17 |
7.13 |
10.92 |
109 |

1038 |
8 |
2019/05/22 10:33:25 |
7.19 |
11.00 |
101 |

STABLEMAX([StabilityChild.pH],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),3,0.2) = TRUE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for pH. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the maximum difference, between the largest and smallest pH values within the last 3 records, is within a tolerance of 0.2 units. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLEMAX([StabilityChild.pH],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),4,0.2) = FALSE

This formula is calculating the stability for the pH values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for pH. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the maximum difference, between the largest and smallest pH values within the last 4 records, is within a tolerance of 0.2 units. The formula returns FALSE as the stability has not been met based on the formula criteria.

STABLERD

The STABLERD function checks that the relative difference between two consecutive values (twice the absolute difference divided by the average of the two expressed as a percentage) is always less than or equal to the tolerance (percent value).

STABLERD(<Parameter_1>,<Parameter_2>,<NumericParameter_1>,<NumericParameter_2>,{<OptionalBooleanParameter_1>})

Aggregate = Yes

Example 1 – Collect Form Stability (no child forms)

Date |
pH |
Temp |
Turb |
---|---|---|---|

2019/05/20 08:33:27 |
6.44 |
10.43 |
142 |

2019/05/20 08:36:18 |
5.12 |
9.47 |
134 |

2019/05/20 08:39:31 |
7.01 |
10.34 |
109 |

2019/05/20 08:42:55 |
8.13 |
10.07 |
122 |

2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

STABLERD([Stability.Turb],[Stability.Date],3,10) = TRUE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for Turb. This stability function is checking that the relative difference (%), of the Turb values within the last 3 records, is within a tolerance of 10%. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLERD([Stability.Turb],[Stability.Date],4,10) = FALSE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for Turb. This stability function is checking that the relative difference (%), of the Turb values within the last 4 records, to be within a tolerance of 10%. The formula returns FALSE as the stability has not been met based on the formula criteria.

Example 2 – Collect ParentForm Stability and ChildForm StabilityChild

ParentForm – Stability

#id (Parent Form) |
Location (Form Records) |
---|---|

1023 |
Well ID 001 |

1038 |
Well ID 002 |

ChildForm – StabilityChild

#parent_#id |
#id (Child Form) |
Date |
pH |
Temp |
Turb |
---|---|---|---|---|---|

1023 |
1 |
2019/05/20 08:45:49 |
9.34 |
9.86 |
119 |

1023 |
2 |
2019/05/20 08:48:26 |
7.02 |
11.03 |
106 |

1023 |
3 |
2019/05/20 08:52:04 |
7.10 |
11.10 |
97 |

1023 |
4 |
2019/05/20 08:54:57 |
7.20 |
11.19 |
102 |

1038 |
5 |
2019/05/22 10:24:40 |
8.85 |
12.09 |
128 |

1038 |
6 |
2019/05/22 10:26:59 |
7.07 |
10.81 |
103 |

1038 |
7 |
2019/05/22 10:29:17 |
7.13 |
10.92 |
109 |

1038 |
8 |
2019/05/22 10:33:25 |
7.19 |
11.00 |
101 |

STABLERD([StabilityChild.Turb],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),3,10) = TRUE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 3 record values for Turb. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the relative difference (%), of the Turb values within the last 3 records, is within a tolerance of 10%. The formula returns TRUE as the stability has been met based on the formula criteria.

STABLERD([StabilityChild.Turb],FILTER(EQ([#parent_#id],[StabilityChild.#parent_#id]),[Stability.Date]),4,10) = FALSE

This formula is calculating the stability for the turbidity (Turb) values of the above table. The formula is first sorting the records based on the date and time, and then using the last 4 record values for Turb. The sorting is supplemented with the FILTER and EQ functions to ensure the correct child form fields, from the associated parent form record, are used. This stability function is checking that the relative difference (%), of the Turb values within the last 4 records, is within a tolerance of 10%. The formula returns FALSE as the stability has not been met based on the formula criteria.

Copyright © 2021 EarthSoft, Inc • Modified: 02 Feb 2021