Learn R Programming

cg (version 1.0-3)

profileGraph: Graph Profiles of Experimental Units

Description

Generic function to create a graph of experimental unit profiles of a data object created by the cg package.

Usage

profileGraph(data, ...)

Arguments

data
A data object created with a prepare function or method from the cg package. The only class of object currently valid is cgPairedDifferenceData, which is created by the prepareCGPairedDifferenceData function.
...
Additional arguments, depending on the specific method written for the object. Currently, there is only one such specific method; see profileGraph.cgPairedDifferenceData for any additional arguments that can be specified.

Value

The main purpose is the side effect of graphing to the current device. See the specific methods for discussion of any return values.

Details

Individual points are jittered, and open circles are used to alleviate potential overlap and the danger of representing multiple points as a single point.

The profile graph for paired difference data is the simplest of profiles as each experimental unit has exactly two points connected by a straight line. Labels for the experimental units are added for identification.

Minimum and maximum values from ranges of data are respectively labeled in the bottom and top left corners of graph regions. Tick marks are attempted to be chosen wisely. For log-scaled axes in particular, leading digits of 2, 5, and 10 for values are included if possible. Since the algorithm is empirical, the ticklabels argument is available for further refinement or complete replacement of tickmarks.

See Also

profileGraph.cgPairedDifferenceData

Examples

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

# Graph the data on the original scale instead of the log scale.
profileGraph(anorexiaFT.data, logscale=FALSE)

Run the code above in your browser using DataLab