sub.crf: Make sub CRF

Description Usage Arguments Details Value See Also Examples

Description

Generate sub CRF by selecting some nodes

Usage

1

Arguments

crf

The CRF generated by make.crf

subset

The vector of selected node ids

Details

The function will generate a new CRF from a given CRF by selecting some nodes. The vector subset contains the node ids selected to generate the new CRF. Unlike clamp.crf, the potentials of remainning nodes and edges are untouched.

Value

The function will return a new CRF with additional components:

original

The original CRF data.

node.id

The vector of the original node ids for nodes in the new CRF.

node.map

The vector of the new node ids for nodes in the original CRF.

edge.id

The vector of the original edge ids for edges in the new CRF.

edge.map

The vector of the new edge ids for edges in the original CRF.

See Also

make.crf, clamp.crf

Examples

1
2
3
library(CRF)
data(Small)
crf <- sub.crf(Small$crf, c(2, 3))


Search within the CRF package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.