Unlimited learning, half price | 50% off

Last chance! 50% off unlimited learning

Sale ends in


catnet (version 1.16.1)

cnOrder-method: Network Node Order

Description

The function returns an order of the nodes of a network that is compatible with its parent structure.

Usage

cnOrder(object)

Value

a list of node indices.

Arguments

object

a catNetwork or a list of node parents.

Author

N. Balov, P. Salzman

Details

An order is compatible with the parent structure of a network if each node has as parents only nodes appearing earlier in that order. That such an order exists is guaranteed by the fact that every catNetwork is a DAG (Directed Acyclic Graph). The result is one order out of, eventually, many possible.

Examples

Run this code
  cnet <- cnRandomCatnet(numnodes=20, maxParents=3, numCategories=2)
  cnOrder(object=cnet)

Run the code above in your browser using DataLab