Learn R Programming

cg (version 1.0-3)

print.cgOneFactorGlobalTest: Print One Factor Global F-test object with some format options

Description

Print a cgOneFactorGlobalTest object, which contains global F-test p-value information taken from a cgOneFactorFit object.

Usage

"print"(x, title = NULL, endptname = NULL, ...)

Arguments

x
An cgOneFactorGlobalTest object, typically created by globalTest.cgOneFactorFit.
title
The title printed out with the p-value. If NULL, it is set to be "Group Test P-value of" the analysisname value in the settings slot of the cgOneFactorGlobalTest object.
endptname
The endpoint name, printed out with the p-value. If NULL, it is set to the endptname value in the settings slot of the cgOneFactorGlobalTest object.
...
Additional arguments. Only one is currently valid:
model
For cgOneFactorGlobalTest objects that have p-values derived from classical least squares lm or resistant & robust rlm fits, the following argument values are possible:
"both"
Both the ordinary classical least squares and resistant & robust p-values are printed. This is the default when both fits are present in the cgOneFactorGlobalTest object specified in the x argument.

"olsonly"
Only the ordinary classical least squares p-value is printed.

"rronly"
Only the resistant & robust approximated p-value is printed.

For other possible cgOneFactorGlobalTest p-value components such as accelerated failure time or unequal variance models, the model argument is not relevant, and the single p-value will just be printed for these model types.

Value

print.cgOneFactorGlobalTest returns invisible. The main purpose is the side effect of printing to the current output connection, which is typically the console.

Details

The smallest actual p-value that will be printed is 0.001. Anything less than 0.001 will be displayed as < 0.001. If you need more digits, see the cgOneFactorGlobalTest object.

The notion of a global F test, or equivalently, of $R^2$, for resistant & robust linear models is murky, as no clear theoretical analogue to the ordinary classical least squares approach exists. See cgOneFactorGlobalTest for details, and regard the output p-value here as ad-hoc.

The object is printed using a mix of cat and print calls. See cgOneFactorGlobalTest for details of the *.gpval and other object slots.

See Also

cgOneFactorGlobalTest

Examples

Run this code
data(canine)
canine.data <- prepareCGOneFactorData(canine, format="groupcolumns",
                                      analysisname="Canine",
                                      endptname="Prostate Volume",
                                      endptunits=expression(plain(cm)^3),
                                      digits=1, logscale=TRUE, refgrp="CC")
canine.fit <- fit(canine.data)

canine.global <- globalTest(canine.fit)

print(canine.global)


Run the code above in your browser using DataLab