plotSubGroups {longitudinalData} | R Documentation |
Plot the trajectories of all the subgroups on several graph (one on
each graph) of an object LongData
relativly
to a Partition
. This function can plot the individual trajectories,
the mean trajectories or both.
plotSubGroups(x, y, ...)
x |
[LongData]: Object containing the trajectories to plot. |
y |
[Partition] : Give the Partition used to color the individual trajectories. If y is missing, a
Partition with a single cluster is considered. |
... |
Graphical parameters to be passed to methods (see plot ). For LongData object specificly :
|
Plot the trajectories of all the subgroups on several graph (one on
each graph) of an object LongData
relativly
to a Partition
. This function can plot the individual trajectories,
the mean trajectories or both.
Some graphical parameters are available
twice, once for the individual trajectories (like type
or col
), once for the
mean trajectories (like type.mean
or col.mean
).
Christophe Genolini
PSIGIAM: Paris Sud Innovation Group in Adolescent Mental Health
INSERM U669 / Maison de Solenn / Paris
Contact author : <genolini@u-paris10.fr>
############# ### Building data ld <- gald() par(ask=TRUE) ### Default ploting plotSubGroups(ld) ### Only the trajectories in black plotSubGroups(ld,col=1,type.mean="n") ### Plot according to a partition ### (regular plot, then plotSubGroups part <- partition(clusters=rep(LETTERS[1:4],each=50),nbClusters=4) plot(ld,part,type.mean="n") plotSubGroups(ld,part,type.mean="n") ### Only the mean trajectories, with letters (for publication ?) plotSubGroups(ld,part,type="n",col.mean=1,size=2) ### All at once. plotSubGroups(ld,part) par(ask=FALSE)