nodes() returns the states of a lag sequential analysis fit, one row per
state with its total outgoing and incoming transition counts. In a lag
transition network the states are the nodes, and how often a state is left
and how often it is entered describe its place in the process: a state with
many outgoing but few incoming transitions tends to open episodes, one with
the reverse tends to close them. The marginal totals also set the expected
counts against which every transition is tested.
The shares of all transitions and the initial-state probability are in
as.data.frame(summary(fit), what = "nodes"); the per-transition table is
transitions().
Usage
nodes(fit)
# S3 method for class 'lsa'
nodes(fit)
# S3 method for class 'lsa_group'
nodes(fit)Arguments
- fit
An
lsafit fromlsa(), or a grouped fit fromlsa(..., group = ).
Value
A data.frame with one row per state and the columns state
(matching the from and to names of transitions()), outgoing
and incoming. A grouped fit gives one row per group and state, with
a leading group column.
Examples
nodes(lsa(engagement))
#> state outgoing incoming
#> 1 Active 658 651
#> 2 Average 751 763
#> 3 Disengaged 325 320