From 7d142111c70cf585d27bbe83ce502958d4847f3b Mon Sep 17 00:00:00 2001 From: Niek Den Teuling Date: Wed, 15 May 2024 11:19:12 +0200 Subject: [PATCH] docs: fix CRAN note (#154) --- R/generics.R | 6 ++++-- R/model.R | 5 ----- man/plot-lcModel-method.Rd | 2 +- man/plot-lcModels-method.Rd | 2 +- man/plotClusterTrajectories.Rd | 6 +----- man/plotFittedTrajectories.Rd | 6 +----- man/plotTrajectories.Rd | 6 +----- man/predictPostprob.Rd | 6 +----- 8 files changed, 10 insertions(+), 29 deletions(-) diff --git a/R/generics.R b/R/generics.R index ccd773bd..ea178529 100644 --- a/R/generics.R +++ b/R/generics.R @@ -499,7 +499,7 @@ setGeneric('metric', function( #' @title Plot the fitted trajectories #' @description Plot the fitted trajectories as represented by the given model #' @inheritParams fittedTrajectories -#' @inheritDotParams fittedTrajectories +#' @param ... Additional arguments passed to [fittedTrajectories]. #' @seealso [fittedTrajectories] setGeneric('plotFittedTrajectories', function(object, ...) standardGeneric('plotFittedTrajectories') @@ -512,6 +512,7 @@ setGeneric('plotFittedTrajectories', #' @title Plot cluster trajectories #' @description Plot the cluster trajectories associated with the given model. #' @inheritParams clusterTrajectories +#' @param ... Additional arguments passed to [clusterTrajectories]. #' @seealso [clusterTrajectories] setGeneric('plotClusterTrajectories', function(object, ...) standardGeneric('plotClusterTrajectories') @@ -523,7 +524,7 @@ setGeneric('plotClusterTrajectories', #' @name plotTrajectories #' @title Plot the data trajectories #' @description Plots the output of [trajectories] for the given object. -#' @param ... Additional arguments. +#' @param ... Additional arguments passed to [trajectories]. #' @seealso [trajectories] setGeneric('plotTrajectories', function(object, ...) standardGeneric('plotTrajectories')) @@ -718,6 +719,7 @@ setGeneric('predictForCluster', function(object, newdata = NULL, cluster, ...) { #' @title Posterior probability for new data #' @description Returns the observation-specific posterior probabilities for the given data. #' @param newdata Optional `data.frame` for which to compute the posterior probability. If omitted, the model training data is used. +#' @param ... Additional arguments passed to [postprob]. #' @inheritParams predictForCluster #' @return A N-by-K `matrix` indicating the posterior probability per trajectory per measurement on each row, for each cluster (the columns). #' Here, `N = nrow(newdata)` and `K = nClusters(object)`. diff --git a/R/model.R b/R/model.R index 9b89e323..f2d47f81 100644 --- a/R/model.R +++ b/R/model.R @@ -1160,7 +1160,6 @@ setMethod('predictForCluster', 'lcModel', #' @rdname predictPostprob #' @aliases predictPostprob,lcModel-method #' @description For `lcModel`: The default implementation returns a uniform probability matrix. -#' @inheritDotParams postprob #' @section Implementation: #' Classes extending `lcModel` should override this method to enable posterior probability predictions for new data. #' \preformatted{ @@ -1267,7 +1266,6 @@ setMethod('plot', c('lcModel', 'ANY'), function(x, y, ...) { #' @rdname plotFittedTrajectories #' @aliases plotFittedTrajectories,lcModel-method #' @param ... Arguments passed to [fittedTrajectories()] and [plotTrajectories]. -#' @inheritDotParams plotTrajectories #' @return A `ggplot` object. #' @seealso [plotClusterTrajectories] [plotTrajectories] [plot] #' @examples @@ -1301,8 +1299,6 @@ setMethod('plotFittedTrajectories', 'lcModel', function(object, ...) { #' @param clusterOrder Specify which clusters to plot and the order. #' Can be the cluster names or index. #' By default, all clusters are shown. -#' @inheritDotParams clusterTrajectories -#' @param ... Arguments passed to [clusterTrajectories()], and [ggplot2::geom_line()] for plotting the cluster trajectory lines. #' @return A `ggplot` object. #' @seealso [plotTrajectories] [plot] #' @examples @@ -1377,7 +1373,6 @@ setMethod('plotClusterTrajectories', 'lcModel', #' @export #' @rdname plotTrajectories #' @aliases plotTrajectories,lcModel-method -#' @inheritDotParams trajectories #' @examples #' data(latrendData) #' method <- lcMethodLMKM(Y ~ Time, id = "Id", time = "Time") diff --git a/man/plot-lcModel-method.Rd b/man/plot-lcModel-method.Rd index c23422d8..a69ca630 100644 --- a/man/plot-lcModel-method.Rd +++ b/man/plot-lcModel-method.Rd @@ -6,7 +6,7 @@ \alias{plot,lcModel-method} \title{Plot a lcModel} \usage{ -\S4method{plot}{lcModel}(x, y, ...) +\S4method{plot}{lcModel,ANY}(x, y, ...) } \arguments{ \item{x}{The \code{lcModel} object.} diff --git a/man/plot-lcModels-method.Rd b/man/plot-lcModels-method.Rd index 160f09eb..4534a076 100644 --- a/man/plot-lcModels-method.Rd +++ b/man/plot-lcModels-method.Rd @@ -6,7 +6,7 @@ \alias{plot,lcModels-method} \title{Grid plot for a list of models} \usage{ -\S4method{plot}{lcModels}(x, y, ..., subset, gridArgs = list()) +\S4method{plot}{lcModels,ANY}(x, y, ..., subset, gridArgs = list()) } \arguments{ \item{x}{The \code{lcModels} object.} diff --git a/man/plotClusterTrajectories.Rd b/man/plotClusterTrajectories.Rd index fb4b393f..42e25985 100644 --- a/man/plotClusterTrajectories.Rd +++ b/man/plotClusterTrajectories.Rd @@ -36,11 +36,7 @@ plotClusterTrajectories(object, ...) \arguments{ \item{object}{The (cluster) trajectory data.} -\item{...}{ - Arguments passed on to \code{\link[=clusterTrajectories]{clusterTrajectories}} - \describe{ - \item{\code{}}{} - }} +\item{...}{Additional arguments passed to \link{clusterTrajectories}.} \item{response}{The response variable name, see \link{responseVariable}.} diff --git a/man/plotFittedTrajectories.Rd b/man/plotFittedTrajectories.Rd index d3b17201..9c42ecd8 100644 --- a/man/plotFittedTrajectories.Rd +++ b/man/plotFittedTrajectories.Rd @@ -12,11 +12,7 @@ plotFittedTrajectories(object, ...) \arguments{ \item{object}{The model.} -\item{...}{ - Arguments passed on to \code{\link[=fittedTrajectories]{fittedTrajectories}}, \code{\link[=plotTrajectories]{plotTrajectories}} - \describe{ - \item{\code{}}{} - }} +\item{...}{Arguments passed to \code{\link[=fittedTrajectories]{fittedTrajectories()}} and \link{plotTrajectories}.} } \value{ A \code{ggplot} object. diff --git a/man/plotTrajectories.Rd b/man/plotTrajectories.Rd index de2d83e1..6b4c4859 100644 --- a/man/plotTrajectories.Rd +++ b/man/plotTrajectories.Rd @@ -26,11 +26,7 @@ plotTrajectories(object, ...) \arguments{ \item{object}{The data or model or extract the trajectories from.} -\item{...}{ - Arguments passed on to \code{\link[=trajectories]{trajectories}} - \describe{ - \item{\code{}}{} - }} +\item{...}{Additional arguments passed to \link{trajectories}.} \item{response}{Response variable \code{character} name or a \code{call}.} diff --git a/man/predictPostprob.Rd b/man/predictPostprob.Rd index ced51fe9..9f398201 100644 --- a/man/predictPostprob.Rd +++ b/man/predictPostprob.Rd @@ -14,11 +14,7 @@ predictPostprob(object, newdata = NULL, ...) \item{newdata}{Optional \code{data.frame} for which to compute the posterior probability. If omitted, the model training data is used.} -\item{...}{ - Arguments passed on to \code{\link[=postprob]{postprob}} - \describe{ - \item{\code{}}{} - }} +\item{...}{Additional arguments passed to \link{postprob}.} } \value{ A N-by-K \code{matrix} indicating the posterior probability per trajectory per measurement on each row, for each cluster (the columns).