Description Usage Arguments Details Value Examples
View source: R/calc_summaryStats.R
Calculates summary statistics, and tallys non-detects and NA result values, grouped by site, parameter, and water year (or user-defined calendar year period).
1 2 3 4 5 6 | calc_summaryStats(
x,
pcodes = c("80154", "70331", "00530", "80155", "80225", "91145"),
startMonth = NULL,
endMonth = NULL
)
|
x |
A |
pcodes |
A character vector of parameter codes of interest. Default pcodes are SSC (80154), Sand/silt break on suspended (70331), TSS (00530), SSL (80155), Bedload (80225), Bedload mass (91145) |
startMonth |
Numeric starting month (ex. 1 for January) for user-defined calendar year periods. Default is NULL. |
endMonth |
Numeric ending month (ex. 12 for December) for user-defined calendar year periods. Default is NULL. |
Calculates number of samples, minimum, maximum, median, mean, and standard deviation (if applicable). Non-detects (REMARK_CD = "<") and Averages (REMARK_CD = "A") are not included in calculations. Rejected samples are not included.
A count of the number of non-detect samples and samples where no result value was reported (RESULT_VA = NA
)
is included in the summary. Summary value "n" does not include non-detects or no result reported samples.
Default pcodes are SSC (80154), Sand/silt break on suspended (70331), TSS (00530), SSL (80155), Bedload (80225), Bedload mass (91145)
Statistics are separated by site, parameter, year (WY or user defined CY), and sample method group.
User-defined calendar year. If startMonth
and endMonth
are specified, statistics and counts
will be limited to calendar year samples within the months specified. Ex. If startMonth = 9
and endMonth = 11
,
only samples from September to November will be included in summary stats and counts, and they will be grouped by calendar year.
Sample method groups. Cross section (X-section) is defined as sample method 10 (EWI), 15 (EWT), or 20 (EDI), 40 (multiple verticals). Point or non-cross section (Pt/non-X-section) is defined as sample method 30 (single vertical), 50 (point sample), 55 (composite - multiple point samples), 60 (weighted bottle), 70 (grab sample - dip), 100 (Van Dorn), 900 (SS pumping), 920 (SS BSV DI att), 930 (SS partial depth), 940 (SS partial width), 4033 (suction lift peristaltic), 4080 (peristaltic pump). Samples with missing or other coded method are grouped together.
A dataframe of summary statistics
1 2 3 | data('exampleData', package = "sedReview")
x <- exampleData
summaryStats <- calc_summaryStats(x)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.