addarrows {deal} | R Documentation |
Create networks with all possible arrows to/from nodes with smaller indices added
addarrows(nw, node, data, prior,trylist=vector("list",nw$n))
nw |
an object of class network , in which arrows are inserted. |
node |
an integer, giving the index (column number in data ) of the node in focus. |
data |
a data frame used for learning the network, see network . |
prior |
a list describing parameter priors, generated by jointprior . |
trylist |
a list, used internally for reusing learning of nodes, see maketrylist . |
Used by networkfamily
when constructing all possible networks
for a given node configuration. Tries to insert all possible arrows to
(from) the node in focus from (to) nodes with smaller indices. Each
arrow combination gives rise to extra networks. All networks are
learned with the data in df
using the prior information in
prior
.
A list with two elements
nw |
an object of class networkfamily with all
created networks. All networks have been learned. |
trylist |
an updated list, used internally for reusing learning
of nodes, see maketrylist . |
Susanne Gammelgaard Bøttcher alma@math.auc.dk,
Claus Dethlefsen dethlef@math.auc.dk.
Further information about deal can be found at:
http://www.math.auc.dk/novo/deal.
data(rats) rats.nw <- network(rats) rats.prior <- jointprior(rats.nw,12) rats.nwl <- addarrows(rats.nw,3,rats,rats.prior)$nw plot(rats.nwl)