Auto-triggered Skills for querying R package documentation via WebFetch. Covers CRAN, tidyverse, Shiny, and general R packages.

version
1.0.0

Install

/plugin install r-docs-guide@psychquant-claude-plugins

Run it inside Claude Code after adding the marketplace with /plugin marketplace add PsychQuant/psychquant-claude-plugins.

Contents

Discovered from source

Skills 4

CRAN Package Discovery Guide

Find and compare R packages via WebFetch.

When to Use

When the user needs to find the right R package for a task, or wants to explore what's available.

Execution Steps (IMPORTANT!)

You MUST WebFetch official sources - never recommend packages from memory alone!

Step 1: Identify the domain or task

The user's query: $ARGUMENTS

Step 2: WebFetch relevant sources

For domain exploration — CRAN Task Views:

DomainURL
Bayesianhttps://cran.r-project.org/web/views/Bayesian.html
ClinicalTrialshttps://cran.r-project.org/web/views/ClinicalTrials.html
Clusterhttps://cran.r-project.org/web/views/Cluster.html
Databaseshttps://cran.r-project.org/web/views/Databases.html
Econometricshttps://cran.r-project.org/web/views/Econometrics.html
ExperimentalDesignhttps://cran.r-project.org/web/views/ExperimentalDesign.html
Financehttps://cran.r-project.org/web/views/Finance.html
HighPerformanceComputinghttps://cran.r-project.org/web/views/HighPerformanceComputing.html
MachineLearninghttps://cran.r-project.org/web/views/MachineLearning.html
MetaAnalysishttps://cran.r-project.org/web/views/MetaAnalysis.html
MixedModelshttps://cran.r-project.org/web/views/MixedModels.html
NaturalLanguageProcessinghttps://cran.r-project.org/web/views/NaturalLanguageProcessing.html
Psychometricshttps://cran.r-project.org/web/views/Psychometrics.html
ReproducibleResearchhttps://cran.r-project.org/web/views/ReproducibleResearch.html
Spatialhttps://cran.r-project.org/web/views/Spatial.html
Survivalhttps://cran.r-project.org/web/views/Survival.html
TimeSerieshttps://cran.r-project.org/web/views/TimeSeries.html
WebTechnologieshttps://cran.r-project.org/web/views/WebTechnologies.html

Full list of Task Views: https://cran.r-project.org/web/views/

For a specific package: https://cran.r-project.org/web/packages/{pkg}/index.html

For package search:

  • https://www.rdocumentation.org/search?q={query}
  • https://rdrr.io/search?q={query}

Step 3: Present recommendations

## Recommended Packages for {Task}

| Package | Description | Downloads | Maintained |
|---------|-------------|-----------|------------|
| {pkg1} | ... | ... | ... |
| {pkg2} | ... | ... | ... |

### Recommendation
[Which package to use and why]

### Installation
```r
install.packages(c("{pkg1}", "{pkg2}"))

## Important Reminders

- **Always WebFetch** CRAN or Task Views - don't recommend packages from memory
- Check if packages are actively maintained (last update date)
- Mention if a package is part of tidyverse or has known alternatives

R Docs Guide

Query R package documentation directly via WebFetch across multiple sources.

When to Use

When the user asks about R packages, functions, or needs help with R programming tasks.

Execution Steps (IMPORTANT!)

You MUST WebFetch official documentation - never answer from memory!

Step 1: Identify the package or topic

The user's query: $ARGUMENTS

Step 2: Determine the best documentation source

SourceURL PatternBest For
CRAN Referencehttps://cran.r-project.org/web/packages/{pkg}/index.htmlPackage overview, links
CRAN Manual (PDF)https://cran.r-project.org/web/packages/{pkg}/{pkg}.pdfFull function reference
Vignetteshttps://cran.r-project.org/web/packages/{pkg}/vignettes/Tutorials, guides
RDocumentationhttps://www.rdocumentation.org/packages/{pkg}Searchable docs
tidyverse pkgdownhttps://{pkg}.tidyverse.org/tidyverse packages
Shinyhttps://shiny.posit.co/r/reference/Shiny framework
Bioconductorhttps://bioconductor.org/packages/release/bioc/html/{pkg}.htmlBioinformatics
R Documentationhttps://stat.ethz.ch/R-manual/R-devel/library/{pkg}/html/00Index.htmlBase R packages
CRAN Task Viewshttps://cran.r-project.org/web/views/{topic}.htmlFind packages by domain
rdrr.iohttps://rdrr.io/cran/{pkg}/Quick function lookup

Step 3: WebFetch the documentation

For a specific package, fetch in parallel:

  1. CRAN page: https://cran.r-project.org/web/packages/{pkg}/index.html
  2. RDocumentation: https://www.rdocumentation.org/packages/{pkg}
  3. If tidyverse: https://{pkg}.tidyverse.org/reference/index.html

For a topic/task (e.g., "how to do time series in R"):

  1. CRAN Task View: https://cran.r-project.org/web/views/{relevant-view}.html
  2. RDocumentation search: https://www.rdocumentation.org/search?q={query}

For a specific function:

  1. https://www.rdocumentation.org/packages/{pkg}/topics/{function}
  2. Or https://rdrr.io/cran/{pkg}/man/{function}.html

Step 4: Present findings

## {Package Name}

**Version:** x.y.z | **CRAN:** [link] | **Docs:** [link]

### Description
[What the package does]

### Key Functions
| Function | Description |
|----------|-------------|
| `func()` | ... |

### Installation
```r
install.packages("{pkg}")

Quick Example

library({pkg})
# example code

Related Packages

  • [alternatives or companions]

## Common CRAN Task Views

| Domain | Task View URL |
|--------|--------------|
| Time Series | `https://cran.r-project.org/web/views/TimeSeries.html` |
| Machine Learning | `https://cran.r-project.org/web/views/MachineLearning.html` |
| Bayesian | `https://cran.r-project.org/web/views/Bayesian.html` |
| Spatial | `https://cran.r-project.org/web/views/Spatial.html` |
| Finance | `https://cran.r-project.org/web/views/Finance.html` |
| Clinical Trials | `https://cran.r-project.org/web/views/ClinicalTrials.html` |
| Psychometrics | `https://cran.r-project.org/web/views/Psychometrics.html` |
| Survival | `https://cran.r-project.org/web/views/Survival.html` |
| Web Technologies | `https://cran.r-project.org/web/views/WebTechnologies.html` |
| Reproducible Research | `https://cran.r-project.org/web/views/ReproducibleResearch.html` |

## Important Reminders

- **Always WebFetch** - never answer R package questions from memory
- **Check version** - R packages update frequently, always get current docs
- **Vignettes first** - vignettes are often more useful than function reference
- If a package is not on CRAN, check Bioconductor or GitHub

Shiny Docs Guide

Query Shiny framework documentation directly via WebFetch.

When to Use

When the user builds or debugs Shiny applications.

Execution Steps (IMPORTANT!)

You MUST WebFetch official documentation - never answer from memory!

Step 1: Identify the topic

The user's query: $ARGUMENTS

Step 2: WebFetch from the correct source

Shiny documentation sources:

TopicURL
Shiny R Referencehttps://shiny.posit.co/r/reference/shiny/latest/
Shiny R Articleshttps://shiny.posit.co/r/articles/
Shiny R Galleryhttps://shiny.posit.co/r/gallery/
bslib (Bootstrap)https://rstudio.github.io/bslib/reference/index.html
shinydashboardhttps://rstudio.github.io/shinydashboard/
shinyWidgetshttps://dreamrs.github.io/shinyWidgets/reference/index.html
shinytest2https://rstudio.github.io/shinytest2/reference/index.html
Mastering Shiny (book)https://mastering-shiny.org/
DT (DataTables)https://rstudio.github.io/DT/
plotly for Rhttps://plotly-r.com/

By topic:

TopicURL
Reactivityhttps://shiny.posit.co/r/articles/build/reactivity-overview/
Moduleshttps://shiny.posit.co/r/articles/improve/modules/
Layout Guidehttps://shiny.posit.co/r/articles/build/layout-guide/
Dynamic UIhttps://shiny.posit.co/r/articles/build/dynamic-ui/
Deploymenthttps://shiny.posit.co/r/articles/share/
Performancehttps://shiny.posit.co/r/articles/improve/performance/
Testinghttps://rstudio.github.io/shinytest2/articles/shinytest2.html

Step 3: Present findings

Include working code examples with both ui and server components.

Important Reminders

  • Always WebFetch - Shiny API changes between versions
  • Always show both ui and server parts in examples
  • For deployment questions, check https://shiny.posit.co/r/articles/share/

Tidyverse Docs Guide

Query tidyverse package documentation directly via WebFetch.

When to Use

When the user works with any tidyverse package or asks about tidy data workflows.

Execution Steps (IMPORTANT!)

You MUST WebFetch official documentation - never answer from memory!

Step 1: Identify the package and function

The user's query: $ARGUMENTS

Step 2: WebFetch from the correct pkgdown site

Tidyverse package sites:

PackageReference URLCheatsheet
dplyrhttps://dplyr.tidyverse.org/reference/index.htmlhttps://dplyr.tidyverse.org/articles/dplyr.html
ggplot2https://ggplot2.tidyverse.org/reference/index.htmlhttps://ggplot2.tidyverse.org/articles/ggplot2.html
tidyrhttps://tidyr.tidyverse.org/reference/index.htmlhttps://tidyr.tidyverse.org/articles/tidy-data.html
purrrhttps://purrr.tidyverse.org/reference/index.htmlhttps://purrr.tidyverse.org/articles/base.html
readrhttps://readr.tidyverse.org/reference/index.html—
stringrhttps://stringr.tidyverse.org/reference/index.html—
forcatshttps://forcats.tidyverse.org/reference/index.html—
tibblehttps://tibble.tidyverse.org/reference/index.html—
lubridatehttps://lubridate.tidyverse.org/reference/index.html—
readxlhttps://readxl.tidyverse.org/reference/index.html—
havenhttps://haven.tidyverse.org/reference/index.html—
gluehttps://glue.tidyverse.org/reference/index.html—

For a specific function: https://{pkg}.tidyverse.org/reference/{function}.html

For articles/vignettes: https://{pkg}.tidyverse.org/articles/

Step 3: Present findings

Include: function signature, parameters, return value, and a working example from the docs.

Important Reminders

  • Always WebFetch the pkgdown site - never answer from memory
  • tidyverse functions are well-documented with examples; always include them
  • If a function doesn't exist on the pkgdown site, fall back to https://www.rdocumentation.org/packages/{pkg}/topics/{function}

Sponsors

Details

Marketplace
PsychQuant/psychquant-claude-plugins
Source
plugins/r-docs-guide
Author
Che Cheng
Category
Development

More from PsychQuant/psychquant-claude-plugins

All 42