Learn R Programming

deal (version 1.1-2)

elementin: Is a network element in a list of networks?

Description

Sequentially check if the network is in the list.

Usage

elementin(nw,nwl)

Arguments

nw
A network.
nwl
A network list.

Value

  • TRUE or FALSE

Details

Sequentially, the elements in nwl are compared to nw using nwequal. If this returns TRUE, then search is terminated and TRUE is returned. Otherwise, FALSE is returned.

References

Further information about Deal can be found at: http://www.math.auc.dk/novo/deal.

See Also

nwequal,nwfunique

Examples

Run this code
data(rats)
rats.nw  <- network(rats)
rats.prior <- jointprior(rats.nw,12)
rats.nw <- learn(rats.nw,rats,rats.prior)$nw
allrats <- networkfamily(rats,rats.nw,rats.prior)

elementin(rats.nw,allrats$nw)

Run the code above in your browser using DataLab