docs: make citation guidance unmissable (fmcmc) - #37
Merged
Merged
Conversation
- Dropped the redundant legacy `entry = ` argument. Adds a How to cite note to the README, vignettes and ?fmcmc, plus a startup message, and adds the CRAN DOI. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Thank you for your contribution @gvegayon 🚀! The pkgdown site preview is ready for review 👉 Download here 👈! |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR makes citation guidance for the fmcmc R package much more visible to end users by adding “How to cite” callouts in the README and vignettes, and by updating inst/CITATION metadata to be more complete and robust.
Changes:
- Adds prominent “How to cite” callouts to the README (source and rendered) and to 3 vignettes.
- Adds an attach-time startup message pointing users to
citation("fmcmc"). - Updates
inst/CITATIONentries (adds CRAN DOI for the package, refines citation fields, and resolves the year more defensively).
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| vignettes/workflow-with-fmcmc.Rmd | Adds a short “How to cite” callout near the top of the vignette. |
| vignettes/user-defined-kernels.Rmd | Adds a short “How to cite” callout near the top of the vignette. |
| vignettes/advanced-features.Rmd | Adds a short “How to cite” callout near the top of the vignette. |
| README.qmd | Adds a prominent “How to cite” NOTE callout near the top of the README source. |
| README.md | Adds the rendered “How to cite” NOTE callout near the top of the README. |
| R/zzz.R | Introduces a package attach hook that emits a citation startup message. |
| inst/CITATION | Updates citation entries and adds year resolution fallback logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+1
to
+5
| .onAttach <- function(libname, pkgname) { | ||
| packageStartupMessage( | ||
| "Using fmcmc in your research? Please cite it: citation(\"fmcmc\")" | ||
| ) | ||
| } |
Comment on lines
+4
to
+10
| year <- if (!is.null(meta$`Date/Publication`)) { | ||
| substr(meta$`Date/Publication`, 1, 4) | ||
| } else if (!is.null(meta$Date)) { | ||
| substr(meta$Date, 1, 4) | ||
| } else { | ||
| format(Sys.Date(), "%Y") | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes citation guidance for fmcmc hard to miss, and corrects the citation metadata.
Motivation: the package has far more users than citations, and the usual reason is that people cannot find what to cite. Every change below is aimed at that gap.
inst/CITATIONentry =argument.10.32614/CRAN.package.fmcmcto the package entry (CRAN began minting these in 2024).Date/Publication→Date→ current year, so the entry cannot render as(????).Documentation
> [!NOTE]"How to cite" callout near the top. Both the source (.qmd/.Rmd) and the renderedREADME.mdare updated; the block is static markdown, so no re-render was required..callout-notein.qmd, a blockquote in.Rmd).packageStartupMessageon attach pointing atcitation("fmcmc"). It is suppressible in the normal way and does not fire on::.Verification
utils::readCitationFile()parses the new file against the package DESCRIPTION, and the rendered entries were inspected.R/*.Rfiles stillparse()and allman/*.Rdstill passtools::parse_Rd().🤖 Generated with Claude Code