data("Fisheries_Treaties_6070")
states <- defineNodes(states)
states <- linkEvents(states, sovchanges, attribute = "present")
states <- linkEvents(states, regchanges, attribute = "regime")
states <- linkEvents(states, gdpchanges, attribute = "gdp")
bilatnet <- defineNetwork(bilatnet, nodes = states, directed = FALSE)
bilatnet <- linkEvents(bilatnet, bilatchanges, nodes = states)
createBilat <- defineDependentEvents(
events = bilatchanges[bilatchanges$increment == 1, ],
nodes = states, defaultNetwork = bilatnet
)
contignet <- defineNetwork(contignet, nodes = states, directed = FALSE)
contignet <- linkEvents(contignet, contigchanges, nodes = states)
gatheredData <- GatherPreprocessing(
createBilat ~ inertia(bilatnet) + trans(bilatnet) + tie(contignet)
)
Run the code above in your browser using DataLab