totcount: Summarize Transistion matrix

Description Usage Arguments Value Author(s) See Also Examples

Description

Summarize a transistion matrix to determine the number of times each state occured and the edges, which is the number of times the state changed

Usage

1
totcount(Trans)

Arguments

Trans

n x n Transistion matrix

Value

returns a list with two levels

StateCount

the number of times each state occurs

TransCount

the number of times each transition occurs, the diagonal, which represents a transistion onto itself is 0

Author(s)

Connor F. White

See Also

transMat

Examples

1
2
3
4
5
6
dat<-sample(c("A","B","C","D"),100,replace=TRUE)
x<-transMat(dat, States=c("A","B","C","D"))
counts<-totcount(x)

counts$StateCount
counts$TransCount

ConnorFWhite/AssFunc documentation built on May 20, 2019, 4:07 p.m.