Skip to contents

Create a data.frame with documentation metadata of one or more packages. If you develop a universe, such as the tidyverse or tidymodels, pkgdoc helps you to easily create a universe-wide reference for the pkgdown website of your meta-package.

Usage

reference_package(
  x,
  url_template = NULL,
  url = NULL,
  packages = NULL,
  strip_s3class = TRUE
)

Arguments

x

A character vector giving concepts or package names to match.

url_template

Character. A template to generate links to documentation based on the column names of the output – typically package and topic, e.g. "https://maurolepore.github.io/{package}/reference/{topic}.html" (glue::glue() syntax).

url

Character vector of length-1 giving a base url, e.g. "https://maurolepore.github.io/".

packages

A character vector with the names of packages to limit the search, or NULL to serach in all known libraries.

strip_s3class

TRUE removes the class component of S3 methods.

Value

A dataframe.

Examples

reference_package("datasets")
#> # A tibble: 87 × 5
#>    topic          alias                 title                    concept package
#>    <chr>          <chr>                 <chr>                    <chr>   <chr>  
#>  1 AirPassengers  AirPassengers         Monthly Airline Passeng… Datase… datase…
#>  2 BJsales        BJsales, BJsales.lead Sales Data with Leading… Datase… datase…
#>  3 BOD            BOD                   Biochemical Oxygen Dema… Datase… datase…
#>  4 CO2            CO2                   Carbon Dioxide Uptake i… Datase… datase…
#>  5 ChickWeight    ChickWeight           Weight versus age of ch… Datase… datase…
#>  6 DNase          DNase                 Elisa assay of DNase     Datase… datase…
#>  7 EuStockMarkets EuStockMarkets        Daily Closing Prices of… Datase… datase…
#>  8 Formaldehyde   Formaldehyde          Determination of Formal… Datase… datase…
#>  9 HairEyeColor   HairEyeColor          Hair and Eye Color of S… Datase… datase…
#> 10 Harman23.cor   Harman23.cor          Harman Example 2.3       Datase… datase…
#> # ℹ 77 more rows