readnet {deal} | R Documentation |
Reads/saves a Bayesian network specification in the .net
language (see
http://developer.hugin.com/documentation/net/).
readnet(filename) savenet(nw, filename = "default.net")
filename |
a string, which contains the file name to be read. |
nw |
an object of class network . |
readnet
reads only the structure of a network, i.e. the
directed acyclic graph.
savenet
exports the prob
property for each node in the
network object along with the network structure defined by the parents
of each node.
readnet
creates an object of class network
with
the nodes specified as
in the .net
file. The network
has not been learned and the nodes do not have prob
properties
(see prob.network
).
savenet
creates a file.
The call to readnet(savenet(network))
is not the identity
function as information is thrown away in both savenet
and
readnet
.
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) nw <- network(rats) savenet(nw,"default.net") nw2 <- readnet("default.net") nw2 <- prob.network(nw2,rats)