plotTraj,ClusterLongData {kml} | R Documentation |
~ Function: plotTraj for ClusterLongData ~
Description
plotTraj
plot the trajectories of an object
ClusterLongData
relatively to a Partition
.
Usage
## S4 method for signature 'ClusterLongData,ANY'
plotTraj(x,y,parTraj=parTRAJ(col="clusters"),
parWin=windowsCut(x['nbVar'],addLegend=TRUE),nbSample=1000,...)
Arguments
x |
[ClusterLongData] : Object containing the trajectories to plotTraj.
|
y |
[numeric] or [couple(numeric)] : Give the Partition
to represent. If y is missing, the Partition with
the highest quality criterion (the actif one) is selected. If y is a number,
the first Partition of the sublist c-y is
selected. If y is a couple of numeric, the y[2] th
Partition of the sublist c-y[1] is selected (so y=c(2,3) select the partition
with 2 clusters, the third one).
|
parTraj |
[ParLongData] : Specification of the plotting
parameters of the individual trajectories. Fields that can be changes are
'type','col','pch','xlab' and 'ylab'. In addition to the standard
possible values, the option col="clusters" (the default) can be use to color the individual
trajectories according to their clusters (exemple:
parTraj=parTRAJ(type="o",col="clusters") ). See
ParLongData in package longitudinalData for details.
|
parWin |
[parWindows] : Set the graphical display of
the windows. See ParWindows in package longitudinalData for details.
|
nbSample |
[numeric] : Graphical display of huge sample can
be time consumming. This parameters fixe the maximum number of
trajectories (randomly chosen) that will be drawn.
|
... |
Some other parameters can be passed to the method.
|
Details
plotTraj
the trajectories of an object ClusterLongData
relativly
to the 'best' Partition
, or to the
Partition
define by y
.
Graphical option (col, type, pch
and xlab) can be change using parTraj
.
For more
detail on parTraj
, see object of
class ParLongData
in package longitudinalData
.
See Also
Overview: kml-package
Classes : ClusterLongData
PlotTraj : plotTraj: overview
, plotCriterion
Examples
### Move to tempdir
wd <- getwd()
setwd(tempdir()); getwd()
##################
### Construction of the data
ld <- gald()
kml(ld,3:4,1)
### Basic plotTrajting
plotTraj(ld,3)
### Go back to current dir
setwd(wd)
[Package
kml version 2.5.0
Index]