Skip to contents

DEPRECATED: Please use step_down_RSCABS() instead for new code.

Runs the Rao-Scott adjusted Cochran-Armitage trend test by slices (RSCABS) analysis.The function is adapted from the archived version of RSCABS developed by Joe Swintek et al with CC0 license. It is not updated anymore and included for validation purpose. The modern replacement is step_down_RSCABS().

Usage

runRSCABS(Data, Treatment, Replicate = "", Effects = "", test.type = "RS")

Arguments

Data

A standard data set in the tall format. Every row indicates an organism. The data set must contain columns for the treatment level and every tested histological endpoint.

Treatment

The name of the column that contains the information about the treatment level. Increasing values indicate higher treatments.

Replicate

The name of the column that contains the information about the replicate structure. If the replicate is not specified this will default to running "CA" as the test type.

Effects

The endpoint to be tested. Defaults to all columns that have integers less then 20. The analysis assumes that higher scores indicate a worse outcome.

test.type

Indicate the type of analysis to be performed. Use "RS" to select the Rao-Scott adjustment to the Cochran-Armitage test and "CA" to ignore the adjustment.

Value

a table of the test results for each treatment and injury score.

Details

This function is deprecated. For new analyses, please use the modern implementation in step_down_RSCABS() which provides:

  • Better error handling and input validation

  • More flexible data input formats

  • Improved statistical methodology

  • Better documentation and examples

References

Green, John W. and Springer, Timothy A. and Saulnier, Amy N. and Swintek, Joe, (2014) Statistical analysis of histopathological endpoints. Environmental Toxicology and Chemistry, 33(5), 1108-1116

Author

Joe Swintek

Examples

if (FALSE) { # \dontrun{
## Not run:
#Take the subset corresponding to F0-females of 16 weeks of age
data(exampleHistData)
exampleHistData.sub<-exampleHistData[which(exampleHistData$Generation=='F2' &
             exampleHistData$Genotypic_Sex=='Female' & exampleHistData$Age=='16_wk' ),  ]
 #Run RSCABS
 eampleResults<-runRSCABS(exampleHistData.sub,'Treatment',
                          'Replicate',test.type='RS')
} # }