Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

50 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lotR: latent class analysis of observations organized by tree in R

An R package for Latent Class Models for Observations Organized by Tree Structure (lotR)

zhenkewu badges: Travis CI Build Status

Maintainer: Zhenke Wu, zhenkewu@umich.edu

Table of content

Installation

install.packages("devtools",repos="https://cloud.r-project.org")
devtools::install_github("zhenkewu/lotR")

Overview

lotR is designed for analyzing multivariate binary observations while integrating additional sample related information represented by each observation's membership in the leaves of a given tree. The observations that are closer in the tree are a priori more likely to be grouped together and fitted by a LCM with identical LCM parameters. The model is built on spike-and-slab priors on the increments of a Gaussian diffusion process for each node of the tree. The model is self-adaptive in that it automatically choose the optimal grouping of observations to fit distinct latent class models. The posterior inferential algorithm is based on variational inference and can provide approximate posterior uncertainty quantifications.

lotR works for

  • multivariate binary responses

    • known cut level, pre-specified grouping of observations
    • unknown cut level, which requires self-adaptive grouping of observations
  • The functions' relations in the package lotR can be visualized by

library(DependenciesGraphs) # if not installed, try this-- devtools::install_github("datastorm-open/DependenciesGraphs")
library(QualtricsTools) # devtools::install_github("emmamorgan-tufts/QualtricsTools")
dep <- funDependencies('package:lotR','lcm_tree')
plot(dep)

Examples

  • main function example(lcm_tree)

  • A simple workflow using simulated data and a micky mouse tree can be run in R by example(lcm_tree)

  • lotR is self-adaptive: leaves close in the tree means they are more likely to be grouped together.

  • lotR produces similar results as BayesLCA on fully collapsed tree (ignoring tree information)

About

Integrating Sample Relatedness Information into Latent Class Models: A Tree-Structured Shrinkage Approach

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages