sparsebnPath: sparsebnPath class

Description Usage Arguments Details Methods Examples

Description

Convenience wrapper class for solution paths of DAG learning algorithms: This class represents an entire solution path of an algorithm. Its components are of type sparsebnFit. Also inherits from list.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
sparsebnPath(x)

is.sparsebnPath(x)

## S3 method for class 'sparsebnPath'
print(x, verbose = FALSE, ...)

## S3 method for class 'sparsebnPath'
summary(object, ...)

## S3 method for class 'sparsebnPath'
plot(x, labels = FALSE, ...)

Arguments

x

A list or an object of type sparsebnPath. Should only be used internally.

verbose

If TRUE, then each estimate in the solution path is printed separately. Do not use for large graphs or large solution paths. (default = FALSE)

...

(optional) additional arguments.

object

an object of type sparsebnPath

labels

TRUE or FALSE. Whether or not to print out labels with summary information for each plot in the solution path.

Details

Each value of lambda in the (discrete) solution path corresponds to a single DAG estimate (see Aragam and Zhou (2015) for details). Internally, this estimate is represented by a sparsebnFit object. The full solution path is then represented as a list of sparsebnFit objects: This class is essentially a wrapper for this list.

Most methods for sparsebnPath objects simply apply lapply to the object in question. The exceptions to this rule apply when the output will always be the same for every component; e.g. num.nodes and num.samples.

Methods

get.adjacency.matrix, get.lambdas, num.nodes, num.edges, num.samples

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## Not run: 
### Learn the cytometry network
library(sparsebn)
data(cytometryContinuous) # from the sparsebn package
cyto.data <- sparsebnData(cytometryContinuous[["data"]], type = "continuous")
cyto.learn <- estimate.dag(cyto.data)

### Inspect the output
class(cyto.learn)
print(cyto.learn)
plot(cyto.learn)

## End(Not run)

itsrainingdata/sparsebnUtils documentation built on June 5, 2019, 5:43 p.m.