R/LDAtopicmodel.R

Defines functions LDAtopicmodel

Documented in LDAtopicmodel

#' Bayesian latent Dirichlet allocation for 16S and metagenomics data.
#'
#' @param stan_data A list of stan data.
#' @param ... Arguments passed to `rstan::sampling` (e.g. iter, chains).
#'
#' @return An object of class `stanfit` returned by `rstan::sampling`.
#' @importFrom rstan sampling
#' @export
LDAtopicmodel <- function(stan_data, ...){
        stan.fit <- rstan::sampling(
          object = stanmodels$lda,
          data = stan_data,
          ...
        )
        return(stan.fit)
}
PratheepaJ/diffTop documentation built on Dec. 18, 2021, 7:48 a.m.