Learn R Programming

PathwaySpace (version 0.99.4)

circularProjection,PathwaySpace-method: Creating 2D-landscape images from graph objects.

Description

circularProjection implements a convolution algorithm to project signal across a 2D-coordinate system.

Usage

# S4 method for PathwaySpace
circularProjection(
  pts,
  knn = 8,
  pdist = 0.15,
  rescale = TRUE,
  verbose = TRUE,
  decay_fun = weibullDecay,
  ...
)

Value

A preprocessed PathwaySpace class object.

Arguments

pts

A PathwaySpace class object.

knn

A single positive integer determining the k-nearest signal sources used in the signal convolution operation.

pdist

A term (in [0,1]) determining a distance unit for the signal convolution related to the image space. This distance will affect the extent over which the convolution operation projects the signal between source- and destination points.

rescale

A single logical value indicating whether to rescale the signal. If the signal >=0, then it will be rescaled to [0,1]; if the signal <=0, then it will be rescaled to [-1,0]; and if the signal in (-Inf,+Inf), then it will be rescaled to [-1,1].

verbose

A single logical value specifying to display detailed messages (when verbose=TRUE) or not (when verbose=FALSE).

decay_fun

A signal decay function. Available: 'Weibull', 'exponential', and 'linear' functions (see weibullDecay).

...

Additional arguments passed to the decay function.

Author

Vinicius Chagas, Victor Apolonio, Mauro Castro, and TCGA Network.

See Also

buildPathwaySpace

Examples

Run this code
# Load a demo igraph
data('gtoy1', package = 'PathwaySpace')

# Create a new PathwaySpace object
pts <- buildPathwaySpace(gtoy1, nrc = 100)
# note: adjust 'nrc' to increase image resolution

# Create a 2D-landscape image
pts <- circularProjection(pts)

Run the code above in your browser using DataLab