From 5f57160fb0d5679f58f2eaf3d58473e747bfc2d3 Mon Sep 17 00:00:00 2001 From: Mahendra Mariadassou Date: Fri, 17 Nov 2023 11:25:19 +0100 Subject: [PATCH] Update documentation of `starting_point()` to avoid warnings when checking the package. --- R/utils.R | 10 +++++++++- man/starting_point.Rd | 13 +++++++++++-- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/R/utils.R b/R/utils.R index 8f2a5bd5..1e1ffdb7 100644 --- a/R/utils.R +++ b/R/utils.R @@ -253,8 +253,16 @@ create_parameters <- function( depths = depths) } -#' Barebone function to compute starting points for B, M and S +#' Helper function for PLNfit initialization. +#' +#' @description +#' Barebone helper function to compute starting points for B, M and S when fitting a PLN. Intended for internal use only. +#' #' @importFrom stats lm.fit +#' @param Y Response matrix +#' @param X Covariate matrix +#' @param O Offset matrix +#' @param w Weight vector starting_point <- function(Y, X, O, w) { # Y = responses, X = covariates, O = offsets (in log scale), w = weights n <- nrow(Y); p <- ncol(Y); d <- ncol(X) diff --git a/man/starting_point.Rd b/man/starting_point.Rd index 73d8ed53..8860323d 100644 --- a/man/starting_point.Rd +++ b/man/starting_point.Rd @@ -2,10 +2,19 @@ % Please edit documentation in R/utils.R \name{starting_point} \alias{starting_point} -\title{Barebone function to compute starting points for B, M and S} +\title{Helper function for PLNfit initialization.} \usage{ starting_point(Y, X, O, w) } +\arguments{ +\item{Y}{Response matrix} + +\item{X}{Covariate matrix} + +\item{O}{Offset matrix} + +\item{w}{Weight vector} +} \description{ -Barebone function to compute starting points for B, M and S +Barebone helper function to compute starting points for B, M and S when fitting a PLN. Intended for internal use only. }