pcp: Projection of points into one dimension.

Description Usage Arguments Details Value Author(s) Examples

Description

Project points onto a principal curve.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
getData(x, ...)

## S4 method for signature 'Pcp'
getData(x, n = NULL)

## S4 method for signature 'Pcp'
initialize(.Object, ..., classes, points.orig, line,
  points.onedim, index, class.color)

## S4 method for signature 'Pcp,missing'
plot(x, y, steps = "all", class.color = NULL, ...)

pcp(mat, ...)

## S4 method for signature 'matrix'
pcp(mat, classes, df = NULL, warn = TRUE,
  class.color = NULL, ...)

## S4 method for signature 'Pcp'
show(object)

Arguments

x

matrix object for the function pcp otherwise it is a Pcp object

...

additional arguments to pass on

n

data to extract from Pcp (NULL gives all)

.Object

internal object

classes

vector in same order as rows in matrix

points.orig

multidimensional points describing the original data

line

multidimensional points describing a line

points.onedim

a vector of points

index

internal index from the projection

class.color

user assigned group coloring scheme

y

default plot param, which should be set to NULL

steps

1,2,3,4,5,6 or "all"

mat

matrix with samples on rows, PCs in columns. Ordered PCs, with PC1 to the left.

df

degrees of freedom, passed to smooth.spline

warn

logical indicating if a change in the default df argument should generate a warning. mostly for internal use.

object

Pcp object

Details

The resulting Pcp object containing results from a principal curve reduction to one dimension. The group and the one dimensional points will be the information needed to carry out a classification using the classify() function. As a help to illustrate the details of the dimension reduction, the information from some critical steps is stored in the object. To visually explore these there is a dedicated plot method for Pcp objects, use plot().

Value

The pcp function returns an object of class Pcp

Author(s)

Jesper R. Gadin and Jason T. Serviss

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
#use demo data
data(pcpMatrix)
classes <- rownames(pcpMatrix)

#run function
prj <- pcp(pcpMatrix, classes)

#getData accessor
getData(prj)

#getData accessor specific
getData(prj, "line")

#plot the result (if dim >2, then plot in 3d)
plot(prj)

#plot the result (if dim=2, then plot in 2d)
prj2 <- pcp(pcpMatrix[,1:2], classes)
plot(prj2)

jasonserviss/ClusterSignificance documentation built on May 9, 2019, 5:56 p.m.