Skip to content
Back to skills

R Dev Docs

ASecurity

R documentation with pkgdown, roxygen2, rmarkdown. Use for package websites and documentation.

  • 5 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added June 4, 2026
datagitdocumentation

Security analysis

A100/100

Scanned June 4, 2026

npx -y skills add LeoLin990405/r-analytics-skill --skill r-dev-docs --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of R Dev Docs?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for R Dev Docs
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/leolin990405-r-dev-docs/badge)](https://www.skillsdirectory.com/skills/leolin990405-r-dev-docs)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: r-dev-docs
description: R documentation with pkgdown, roxygen2, rmarkdown. Use for package websites and documentation.
---

# R Documentation

Package documentation and websites.

## pkgdown

```r
library(pkgdown)

# Build site
build_site()

# Components
build_home()
build_reference()
build_articles()
build_news()

# Preview
preview_site()
```

## _pkgdown.yml

```yaml
url: https://mypackage.github.io/mypackage

template:
  bootstrap: 5
  bootswatch: flatly

navbar:
  structure:
    left: [intro, reference, articles]
    right: [search, github]
  components:
    articles:
      text: Articles
      menu:
        - text: Getting Started
          href: articles/intro.html
        - text: Advanced Usage
          href: articles/advanced.html

reference:
  - title: Data Manipulation
    contents:
      - filter_data
      - transform_data
  - title: Visualization
    contents:
      - starts_with("plot_")

articles:
  - title: Tutorials
    navbar: ~
    contents:
      - intro
      - advanced
```

## Vignettes

```r
# Create vignette
usethis::use_vignette("intro")

# Vignette header
---
title: "Introduction to mypackage"
output: rmarkdown::html_vignette
vignette: >
  %\VignetteIndexEntry{Introduction to mypackage}
  %\VignetteEngine{knitr::rmarkdown}
  %\VignetteEncoding{UTF-8}
---
```

## roxygen2 Tags

```r
#' @title Function Title
#' @description Detailed description
#' @details Additional details
#' @param x Parameter description
#' @return Return value description
#' @export
#' @examples
#' \dontrun{
#'   slow_example()
#' }
#' @family related functions
#' @seealso \code{\link{other_function}}
#' @references Paper citation
#' @keywords internal
#' @noRd
```

## README.Rmd

```r
# Create
usethis::use_readme_rmd()

# Build
devtools::build_readme()

# Badge examples
[![R-CMD-check](https://github.com/user/repo/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/user/repo/actions)
[![Codecov](https://codecov.io/gh/user/repo/branch/main/graph/badge.svg)](https://codecov.io/gh/user/repo)
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in data →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.