# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
init_count_cpp <- function(state, constants) {
.Call('_PerspectiveTopicModel_init_count_cpp', PACKAGE = 'PerspectiveTopicModel', state, constants)
}
init_count2_cpp <- function(state, constants) {
.Call('_PerspectiveTopicModel_init_count2_cpp', PACKAGE = 'PerspectiveTopicModel', state, constants)
}
#' @title
#' pos3d
#' @description
#' Access positions in an vector representation of a 3D array
#'
#' @param x index 1
#' @param y index 2
#' @param z index 3
#' @param dims integer vector of size 3 defining the array
#'
pos3d <- function(x, y, z, dims) {
.Call('_PerspectiveTopicModel_pos3d', PACKAGE = 'PerspectiveTopicModel', x, y, z, dims)
}
#' @title
#' rcategorical
#' @description
#' Sample a categorical variable from an unnormalized proportion
#'
#' @param p a vector of (possoble unnormalized) probabilities to sample from
#'
rcategorical <- function(p) {
.Call('_PerspectiveTopicModel_rcategorical', PACKAGE = 'PerspectiveTopicModel', p)
}
#' @title
#' C++ Perspective sampler
#'
#' @param state a perspective model state file
#' @param count_matrices A list of count matrices
#' @param priors A list of priors
#' @param constants A list of constants
#'
per_sampler_cpp <- function(state, count_matrices, priors, constants) {
.Call('_PerspectiveTopicModel_per_sampler_cpp', PACKAGE = 'PerspectiveTopicModel', state, count_matrices, priors, constants)
}
#' @title
#' C++ Cache optimized Perspective sampler
#'
#' @description
#' C++ Cache optimized Perspective sampler
#'
#' @param state a perspective model state file
#' @param count_matrices A list of count matrices
#' @param priors A list of priors
#' @param constants A list of constants
#'
per_sampler2_cpp <- function(state, count_matrices, priors, constants) {
.Call('_PerspectiveTopicModel_per_sampler2_cpp', PACKAGE = 'PerspectiveTopicModel', state, count_matrices, priors, constants)
}
#' @title
#' C++ Cache optimized Perspective sampler with prior on Phi
#'
#' @description
#' C++ Cache optimized Perspective sampler with prior on Phi
#'
#' @param state a perspective model state file
#' @param count_matrices A list of count matrices
#' @param priors A list of priors
#' @param constants A list of constants
#'
per_sampler3_cpp <- function(state, count_matrices, priors, constants) {
.Call('_PerspectiveTopicModel_per_sampler3_cpp', PACKAGE = 'PerspectiveTopicModel', state, count_matrices, priors, constants)
}
#' @title
#' C++ Cache optimized Perspective sampler with prior on Phi and Theta
#'
#' @description
#' C++ Cache optimized Perspective sampler with prior on Phi and Theta
#'
#' @param state a perspective model state file
#' @param count_matrices A list of count matrices
#' @param priors A list of priors
#' @param constants A list of constants
#'
per_sampler4_cpp <- function(state, count_matrices, priors, constants) {
.Call('_PerspectiveTopicModel_per_sampler4_cpp', PACKAGE = 'PerspectiveTopicModel', state, count_matrices, priors, constants)
}
#' @title
#' C++ Cache optimized Perspective sampler with prior on Phi, Theta and stearing perspectives
#'
#' @description
#' C++ Cache optimized Perspective sampler with prior on Phi and Theta
#'
#' @param state a perspective model state file
#' @param count_matrices A list of count matrices
#' @param priors A list of priors
#' @param constants A list of constants
#'
per_sampler5_cpp <- function(state, count_matrices, priors, constants) {
.Call('_PerspectiveTopicModel_per_sampler5_cpp', PACKAGE = 'PerspectiveTopicModel', state, count_matrices, priors, constants)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.