Learn R Programming

networkDynamic (version 0.11.5)

as.network.networkDynamic: Remove `networkDynamic' class name from networkDynamic object.

Description

Changes the class of a networkDynamic object to a plain network object while leaving all attributes (including dynamic attributes) intact.

Usage

# S3 method for networkDynamic
as.network(x, ...)

Value

Returns the original network with the networkDynamic class name removed but all other attributes unchanged

Arguments

x

A networkDynamic object that will have its class name stripped.

...

Possible additional arguments

Author

Skye Bender-deMoll

Details

The primary use-case for this method is to force some other S3 method (like simulate in the tergm package, plot, or print) to use 'network' instead of 'networkDynamic' in method dispatching. Dynamic features data structures be left intact but not recognized by corresponding methods, so effectively broken.

See Also

See Also as network.extract for extracting parts of a networkDynamic, and network.collapse for extracting part of a networkDynamic as a static network. as.networkDynamic for the inverse operation (adding the networkDynamic class to a static network).

Examples

Run this code
test<-network.initialize(2)
add.edges.active(test,tail=1,head=2,onset=1,terminus=2)
is.networkDynamic(test)
test<-as.network(test)
is.networkDynamic(test)

Run the code above in your browser using DataLab