norm_dist_ci_data: Compute the confidence intervals of fitted normal...

Description Usage Arguments Value

View source: R/norm_ci_functions.R

Description

This is a helper function for norm_hist_ci() which computes the confidence intervals for the fitted normal state dependent distributions by utilizing norm_ci().

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
norm_dist_ci_data(
  x,
  num_states,
  num_variables,
  num_subjects,
  sample,
  state_dep_dist_pooled = FALSE,
  x_step = 0.2,
  n = 100,
  level = 0.975
)

Arguments

x

The data to be fit with an HMM in the form of a 3D array. The first index (row) corresponds to time, the second (column) to the variable number, and the third (matrix number) to the subject number.

num_states

The number of states in the desired HMM.

num_variables

The number of variables in the data.

num_subjects

The number of subjects/trials that generated the data.

sample

A list of mu and sigma sampled according to norm_ci().

state_dep_dist_pooled

A logical variable indiacting whether the state dependent distribution parameters mu and sigma should be treated as equal for all subjects.

x_step

A value indicating the step length for the range of observation values.

n

The number of samples in the Monte Carlo fitting.

level

A number indicating the level of confidence for the desired interval.

Value

A list containing the upper and lower confidence intervals and the parameter esimates.


simonecollier/lizardHMM documentation built on Dec. 23, 2021, 2:24 a.m.