homogeneity_cost: Calculate homogeneity cost

Description Usage Arguments Details See Also Examples

View source: R/homogeneity_cost.R

Description

Calculate the homogeneity cost of a model.

Usage

1
homogeneity_cost(x, is_model_file = TRUE)

Arguments

x

Either the ChromHMM model file or emission probabilities loaded from load_chromhmm_model(...)$emissions or load_chromhmm_emissions(...)

is_model_file

Boolean; TRUE if x is the model file and FALSE if x is emission probabilities.

Details

Calculated by D = sum[k=1 to K]{d_k}^2/K where d_k = sum[h=1 to H]{min(1-E_hk, E_hk)}.

See Also

load_chromhmm_model, load_chromhmm_emissions

Examples

1
2
3
4
5
model_file <-
  system.file("extdata", "model_roadmap18.txt",
              package="hmmpickr")

homogeneity_cost(model_file)

csiu/hmmpickr documentation built on May 14, 2019, 12:24 p.m.