timeInStates | R Documentation |
Calculate proportion of time steps assigned to each state (i.e. “activity budgets”)
timeInStates(m, by = NULL, alpha = 0.95, ncores = 1) ## S3 method for class 'momentuHMM' timeInStates(m, by = NULL, alpha = 0.95, ncores = 1) ## S3 method for class 'HMMfits' timeInStates(m, by = NULL, alpha = 0.95, ncores = 1) ## S3 method for class 'miHMM' timeInStates(m, by = NULL, alpha = 0.95, ncores = 1)
m |
A |
by |
A character vector indicating any groupings by which to calculate the proportions, such as individual (“ID”) or group-level (e.g. sex or age class) covariates. Default is |
alpha |
Significance level for calculating confidence intervals of pooled estimates. Default: 0.95. Ignored unless |
ncores |
Number of cores to use for parallel processing. Default: 1 (no parallel processing). Ignored unless |
If m
is a momentuHMM
object, a data frame containing the estimated activity budgets for each state (grouped according to by
). If m
is a miHMM
or HMMfits
object, a list containing the activity budget
estimates, standard errors, lower bounds, and upper bounds across all imputations.
# m is a momentuHMM object (as returned by fitHMM), automatically loaded with the package m <- example$m timeInStates(m) timeInStates(m, by = "ID")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.