Several auxilliary functions for Petri Net objects.

n_places(PN)

n_transitions(PN)

n_flows(PN)

n_nodes(PN)

nodes(PN)

rename_transitions(PN, .f, ...)

rename_places(PN, .f, ...)

add_places(PN, .p)

add_transitions(PN, .t)

add_flows(PN, .flows)

Arguments

PN

A petri net

.f

A function name to apply for renaming

...

Additional arguments

.p

A character vector of places

.t

A character vector of transitions

.flows

A data.frame with a to and from column