From d2811c0cf3420a12e6593aae4f1ab0ba4da175a4 Mon Sep 17 00:00:00 2001 From: lilyclements Date: Wed, 12 Jun 2024 17:07:09 +0100 Subject: [PATCH] import ::: functions --- R/read_corpora_to_ggwalter_lieth.R | 6 ++++-- R/slopegraph.R | 3 +-- man/slopegraph.Rd | 3 +-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/R/read_corpora_to_ggwalter_lieth.R b/R/read_corpora_to_ggwalter_lieth.R index 34d2167..51cc9e4 100644 --- a/R/read_corpora_to_ggwalter_lieth.R +++ b/R/read_corpora_to_ggwalter_lieth.R @@ -586,13 +586,15 @@ convert_to_list <- function(x) { #' } #' @export getExample <- function (topic, package = NULL, lib.loc = NULL, character.only = TRUE, give.lines = FALSE, local = FALSE, echo = TRUE, verbose = getOption("verbose"), setRNG = FALSE, ask = getOption("example.ask"), prompt.prefix = abbreviate(topic, 6), run.dontrun = FALSE, run.donttest = interactive()) { + index.search < -utils::getFromNamespace("index.search", "utils") + `.getHelpFile` <- utils::getFromNamespace(".getHelpFile", "utils") if (!character.only) { topic <- substitute(topic) if (!is.character(topic)) topic <- deparse(topic)[1L] } pkgpaths <- find.package(package, lib.loc, verbose = verbose) - file <- utils:::index.search(topic, pkgpaths, firstOnly = TRUE) + file <- index.search(topic, pkgpaths, firstOnly = TRUE) if (!length(file)) { warning(gettextf("no help found for %s", sQuote(topic)), domain = NA) @@ -604,7 +606,7 @@ getExample <- function (topic, package = NULL, lib.loc = NULL, character.only = pkgname <- basename(packagePath) lib <- dirname(packagePath) tf <- tempfile("Rex") - tools::Rd2ex(utils:::.getHelpFile(file), tf, commentDontrun = !run.dontrun, + tools::Rd2ex(.getHelpFile(file), tf, commentDontrun = !run.dontrun, commentDonttest = !run.donttest) if (!file.exists(tf)) { if (give.lines) diff --git a/R/slopegraph.R b/R/slopegraph.R index df3d21b..bcf8e6a 100644 --- a/R/slopegraph.R +++ b/R/slopegraph.R @@ -10,8 +10,7 @@ #' #' @param data a dataframe or an object that can be coerced to a dataframe. #' Basic error checking is performed, to include ensuring that the named columns -#' exist in the dataframe. See the \code{\link{newcancer}} dataset for an example of -#' how the dataframe should be organized. +#' exist in the dataframe. #' @param x a column inside the dataframe that will be plotted on the x axis. #' Traditionally this is some measure of time. The function accepts a column of class #' ordered, factor or character. NOTE if your variable is currently a "date" class diff --git a/man/slopegraph.Rd b/man/slopegraph.Rd index 629e956..977b566 100644 --- a/man/slopegraph.Rd +++ b/man/slopegraph.Rd @@ -25,8 +25,7 @@ slopegraph( \arguments{ \item{data}{a dataframe or an object that can be coerced to a dataframe. Basic error checking is performed, to include ensuring that the named columns -exist in the dataframe. See the \code{\link{newcancer}} dataset for an example of -how the dataframe should be organized.} +exist in the dataframe.} \item{x}{a column inside the dataframe that will be plotted on the x axis. Traditionally this is some measure of time. The function accepts a column of class