Learn R Programming

rgr (version 1.1.15)

gx.triples.aov: Carries out a 3-Level Staggered ANOVA and Estimates Variance Components

Description

Function to undertake an ANOVA for the unbalanced triplicates from a GSC NGR or Tri-National survey. The data must be in the following order for each triplicate: Analytical Duplicate, Field Duplicate for the Analytical Duplicate Split, other Field Duplicate. The results replicate those generated by the UANOVA (Garrett and Goss, 1980) computer program. Optionally the data may be logarithmically (base 10) transformed.

Usage

gx.triples.aov(x, xname = deparse(substitute(x)), log = FALSE,
	table = FALSE)

Arguments

x

a file of triplicate determinations, the order is critical, see Details below.

xname

by default the character string for the data file name, x, is used for the table title. An alternate title can be displayed with xname = "text string", see Examples.

log

if a logarithmic transformation of the data is required to meet homogeneity of variance considerations (i.e. severe heteroscedasticity) set log = TRUE. This is also advisable if the range of the observations exceeds 1.5 orders of magnitude.

table

set table = TRUE if the input data file is to be displayed. the default is no display.

Details

As noted above, the order of the data is critical and must be as follows for each triplicate: Analytical Duplicate, Field Duplicate for the Analytical Duplicate Split, other Field Duplicate. The 'other Field Duplicate' is equivalent to a regular regional-coverage sample, but is at a 'Field Duplicate' site. Thus below, x[i,1] will contain the Analytical Duplicates, x[i,2] the Field Duplicates from which the Analytical Duplicates were split, and x[i,3] the other analytically unduplicated Field Duplicates. See Details in triples.test1 for additional information.

References

Bainbridge, T.R., 1963. Staggered, nested designs for estimating variance components. American Society for Quality Control, Convention Transactions, pp. 93-103.

Garrett, R.G., 2013. Assessment of local spatial and analytical variability in regional geochemical surveys with a simple sampling scheme. Geochemistry: Exploration, Environment, Analysis, 13(4):349-354, doi 10.1144.geochem2011-085.

Garrett, R.G. & Goss, T.I., 1980. UANOVA: A Fortran IV program for unbalanced nested anaylsis of variance. Mathematical Geology, 6(1):35-60.

Satterthwaite, F.E., 1946. An approximate distribution of estimates of variance components. Biometrics, 2(2):110-114.

Snee, R.D., 1974. Computation and use of expected mean squares in Analysis of Variance. Journal of Quality Technology, 6(3):128-137.

See Also

ltdl.fix.df, remove.na, triples.test1, gx.triples.fgx, triples.test2

Examples

Run this code
# NOT RUN {
## Make test data available
data(triples.test1)
attach(triples.test1)

## Carry out unbalanced ANOVA
gx.triples.aov(Ba_ppm, xname = 
"Ba (mg/kg - Aqua Regia digestion) in <2 mm unmilled C-horizon soil")

## Detach test data
detach(triples.test1)
# }

Run the code above in your browser using DataLab