as.BinaryNet function

Convert to either an UndirectedNet or DirectedNet object