Skip to content

Load mlumr and ggplot2 once per vignette - #114

Merged
choxos merged 1 commit into
mainfrom
docs/vignette-library-once
Sep 18, 2026
Merged

choxos merged 1 commit into
mainfrom
docs/vignette-library-once

Conversation

@choxos

@choxos choxos commented Sep 18, 2026 •

Copy link
Copy Markdown
Owner

Six vignettes loaded mlumr and ggplot2 twice: once in the setup chunk that also sets mc.cores, and again at the top of the worked example. The second copy is gone from both the precompile source (.Rmd.orig) and the knitted .Rmd; library() prints nothing, so the knitted output needs no rebuild.

No set.seed() was added: the sampler takes seed = 2026 in every mlumr() call, the integration points are an unscrambled Sobol sequence, the survival STC bootstrap is passed seed = 2026, and every chunk that draws random numbers in R already sets the seed directly above it.

Checks: one library(mlumr) per file in all twelve files; the repository checks on vignette currency pass (180 assertions); 28 deletions, no other change.

Summary by CodeRabbit

  • Documentation
    • Simplified vignette setup by removing repeated package-loading statements.
    • All examples continue to use the required packages and datasets as before.
    • No changes to the documented analyses or user-facing functionality.

Six vignettes repeated library(mlumr) and library(ggplot2) at the top of
the worked example after the setup chunk had already loaded them. The
repeat is removed from the precompile sources and the knitted files.
Copilot AI lite review requested due to automatic review settings September 18, 2026 14:27
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Sep 18, 2026 •

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Essentials

Run ID: 7629b608-ee2f-41e3-bc10-f658c3b655c2

📥 Commits

Reviewing files that changed from the base of the PR and between 006b604 and 4e9f105.

📒 Files selected for processing (12)
  • vignettes/binary-outcomes.Rmd
  • vignettes/binary-outcomes.Rmd.orig
  • vignettes/choosing-a-method.Rmd
  • vignettes/choosing-a-method.Rmd.orig
  • vignettes/continuous-outcomes.Rmd
  • vignettes/continuous-outcomes.Rmd.orig
  • vignettes/count-outcomes.Rmd
  • vignettes/count-outcomes.Rmd.orig
  • vignettes/fitting-and-diagnostics.Rmd
  • vignettes/fitting-and-diagnostics.Rmd.orig
  • vignettes/survival-outcomes.Rmd
  • vignettes/survival-outcomes.Rmd.orig
💤 Files with no reviewable changes (12)
  • vignettes/count-outcomes.Rmd.orig
  • vignettes/fitting-and-diagnostics.Rmd
  • vignettes/binary-outcomes.Rmd.orig
  • vignettes/continuous-outcomes.Rmd.orig
  • vignettes/survival-outcomes.Rmd.orig
  • vignettes/binary-outcomes.Rmd
  • vignettes/continuous-outcomes.Rmd
  • vignettes/count-outcomes.Rmd
  • vignettes/fitting-and-diagnostics.Rmd.orig
  • vignettes/choosing-a-method.Rmd
  • vignettes/choosing-a-method.Rmd.orig
  • vignettes/survival-outcomes.Rmd

Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 1 review per hour.


📝 Walkthrough

Walkthrough

The pull request removes redundant mlumr and ggplot2 library calls from six vignette files and their data-preparation chunks. Earlier package-loading code remains unchanged.

Changes

Vignette package-loading cleanup

Layer / File(s) Summary
Remove redundant library calls
vignettes/*.Rmd, vignettes/*.Rmd.orig
The vignettes no longer repeat package attachment calls in setup or data-preparation chunks. Existing earlier package initialization remains in place.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Refactor

Merge Risk: ⚪ Minimal · up to 4e9f1

The cleanup preserves package availability and paired vignette-source behavior. No merge-blocking risk remains.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the change, reproducibility considerations, and verification results. It does not follow the required template because it omits the Type of Change, Statistical or User-Facing … Add all required template sections. Select the applicable Type of Change options, state the user-facing and statistical impact, complete the Documentation and Checklist sections, and place the verification commands and results under a Verif…
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the main change: loading mlumr and ggplot2 once per vignette.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description explains the change, reproducibility considerations, and verification results. It does not follow the required template because it omits the Type of Change, Statistical or User-Facing Impact, Documentation, and Checklist sections, and it does not use the required Verification heading or command-and-result block.

Resolution

Add all required template sections. Select the applicable Type of Change options, state the user-facing and statistical impact, complete the Documentation and Checklist sections, and place the verification commands and results under a Verification heading.

  • Fix all pre-merge checks with AI
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

@choxos
choxos merged commit 977eeb4 into main Sep 18, 2026
6 checks passed
@choxos
choxos deleted the docs/vignette-library-once branch September 18, 2026 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants