print.cgPairedDifferenceSampleSizeTable {cg}R Documentation

Print a Paired Difference Sample Size Table object with some format options

Description

Print a cgPairedDifferenceSampleSizeTable object, which contains a table of sample size estimates based on a cgPairedDifferenceFit object.

Usage

## S4 method for signature 'cgPairedDifferenceSampleSizeTable'
print(x, title=NULL, endptname=NULL, ...)

Arguments

x

A cgPairedDifferenceSampleSizeTable object, typically created by
samplesizeTable.cgPairedDifferenceFit.

title

The title for the table. If NULL, it is set to be "Sample Size Table from" concatenated to planningname value in the settings slot of the
cgPairedDifferenceSampleSizeTable object.

endptname

The endpoint name, printed out with the table. If NULL, it is set to the endptname value from the settings slot of the cgPairedDifferenceSampleSizeTable object.

...

Additional arguments. None are currently defined.

Details

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

Value

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

Note

Contact cg@billpikounis.net for bug reports, questions, concerns, and comments.

Author(s)

Bill Pikounis [aut, cre, cph], John Oleynick [aut], Eva Ye [ctb]

See Also

cgPairedDifferenceSampleSizeTable

Examples

data(anorexiaFT)

anorexiaFT.data <- prepareCGPairedDifferenceData(anorexiaFT, format="groupcolumns",
                                                 analysisname="Anorexia FT",
                                                 endptname="Weight",
                                                 endptunits="lbs",
                                                 expunitname="Patient",
                                                 digits=1,
                                                 logscale=TRUE)

anorexiaFT.fit <- fit(anorexiaFT.data)

## The interest is in increased weight for the anorexia FT
## (family treatment) group of patients

anorexiaFT.samplesize <- samplesizeTable(anorexiaFT.fit, direction="increasing",
                         mmdvec=c(5, 10, 15, 20), display="none")

print(anorexiaFT.samplesize)

## The above two calls produce the same screen output as
samplesizeTable(anorexiaFT.fit, direction="increasing",
                mmdvec=c(5, 10, 15, 20))

## since the default in the call is display="print"


[Package cg version 1.0-3 Index]