From a87022ca8e6f85087f01e9ad8094a2d3a88fa67f Mon Sep 17 00:00:00 2001 From: Jan Wijffels Date: Sun, 15 Mar 2020 09:47:25 +0100 Subject: [PATCH] documentation --- R/btm.R | 8 ++++---- man/BTM.Rd | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/R/btm.R b/R/btm.R index 60420cc..5fb7915 100644 --- a/R/btm.R +++ b/R/btm.R @@ -25,12 +25,12 @@ #' @param background logical if set to \code{TRUE}, the first topic is set to a background topic that #' equals to the empirical word distribution. This can be used to filter out common words. Defaults to FALSE. #' @param trace logical indicating to print out evolution of the Gibbs sampling iterations. Defaults to FALSE. -#' @param biterms optionally, your own set of biterms to use for modelling. +#' @param biterms optionally, your own set of biterms to use for modelling.\cr #' This argument should be a data.frame with column names doc_id, term1, term2 and cooc, indicating how many times each biterm (as indicated by terms term1 and term2) -#' is occurring within a certain doc_id. The field cooc indicates how many times this biterm happens with the doc_id. +#' is occurring within a certain doc_id. The field cooc indicates how many times this biterm happens with the doc_id. \cr #' Note that doc_id's which are not in \code{data} are not allowed, as well as terms (in term1 and term2) which are not also in \code{data}. -#' See the examples. -#' If provided, ignores the \code{window} argument and the \code{data} argument will only be used to calculate the background word frequency distribution. +#' See the examples.\cr +#' If provided, the \code{window} argument is ignored and the \code{data} argument will only be used to calculate the background word frequency distribution. #' @note #' A biterm is defined as a pair of words co-occurring in the same text window. #' If you have as an example a document with sequence of words \code{'A B C B'}, and assuming the window size is set to 3, diff --git a/man/BTM.Rd b/man/BTM.Rd index d5021ea..efae04d 100644 --- a/man/BTM.Rd +++ b/man/BTM.Rd @@ -29,12 +29,12 @@ equals to the empirical word distribution. This can be used to filter out common \item{trace}{logical indicating to print out evolution of the Gibbs sampling iterations. Defaults to FALSE.} -\item{biterms}{optionally, your own set of biterms to use for modelling. +\item{biterms}{optionally, your own set of biterms to use for modelling.\cr This argument should be a data.frame with column names doc_id, term1, term2 and cooc, indicating how many times each biterm (as indicated by terms term1 and term2) -is occurring within a certain doc_id. The field cooc indicates how many times this biterm happens with the doc_id. +is occurring within a certain doc_id. The field cooc indicates how many times this biterm happens with the doc_id. \cr Note that doc_id's which are not in \code{data} are not allowed, as well as terms (in term1 and term2) which are not also in \code{data}. -See the examples. -If provided, ignores the \code{window} argument and the \code{data} argument will only be used to calculate the background word frequency distribution.} +See the examples.\cr +If provided, the \code{window} argument is ignored and the \code{data} argument will only be used to calculate the background word frequency distribution.} } \value{ an object of class BTM which is a list containing