Skip to content

Use autoplot for curve params in methodology vignette#511

Draft
Copilot wants to merge 6 commits intomainfrom
copilot/fix-plot-curve-params-one-ab-error
Draft

Use autoplot for curve params in methodology vignette#511
Copilot wants to merge 6 commits intomainfrom
copilot/fix-plot-curve-params-one-ab-error

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 26, 2026

Thank you for taking the time to submit a pull request!

To maximize the chances of acceptance:

  • The title of your PR should briefly describe the change.
  • Commit/merge messages to be included in NEWS.md should begin with -.
  • Code should follow the tidyverse style guide.
  • Documentation should use roxygen2, with Markdown syntax.
  • Contributions should include unit tests (using testthat).

For more information see Contributing.

The methodology vignette example relied on a deprecated plotting helper, resulting in missing curves in the rendered figure. This switches the example to the curve_params autoplot method and records the documentation update with a version bump.

  • Vignette update
    • Replace plot_curve_params_one_ab() with autoplot() for curve params and keep the same plot composition.
  • Metadata
    • Bump development version and add a Documentation entry in NEWS.
curve1 |>
  autoplot(
    quantiles = NULL,
    log_y = FALSE,
    n_curves = 1
  ) +
  xlim(0, 100) +
  theme_minimal()

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • https://storage.googleapis.com/cos-osf-prod-files-us-east1/eb679c16124f859a9a715a4b48babdcaad12c23a1e82b8a21f0e471aaa4b216d
    • Triggering command: /opt/R/4.5.3/lib/R/bin/exec/R /opt/R/4.5.3/lib/R/bin/exec/R -e library(serocalculator);~+~library(dplyr);~+~library(ggplot2);~+~cur_ai~+~<-~+~'HlyE_IgG';~+~curves~+~<-~+~'REDACTED'~+~|>~+~load_sr_params()~+~|>~+~filter(iter~+~<~+~50);~+~curve1~+~<-~+~curves~+~|>~+~filter(iter~+~==~+~5,~+~antigen o -e /R/include ges=datasets,utils,grDevices,graphics,stats,methods -e 'tryCatch(parallel:::.workRSOCK,error=fun-c de (http block)

If you need me to access, download, or install something from one of these locations, you can either:


⌨️ Start Copilot coding agent tasks without leaving your editor — available in VS Code, Visual Studio, JetBrains IDEs and Eclipse.

Copilot AI changed the title [WIP] Fix error in plot_curve_params_one_ab function Fix plot_curve_params_one_ab() error when iter values don't start at 1 Mar 26, 2026
Copilot AI requested a review from kristinawlai March 26, 2026 04:50
@kristinawlai
Copy link
Copy Markdown
Collaborator

@copilot That still didn't fix the issue in this code in methodology.qmd. The plot is created, but the curve is completely missing on the plot: library(serocalculator)
library(dplyr)

Import longitudinal antibody parameters from OSF

curves <-
"https://osf.io/download/rtw5k/" %>%
load_sr_params() %>%
filter(iter < 50)

curve1 <-
curves %>%
filter(
iter == 5,
antigen_iso == cur_ai
)
library(ggplot2)

curve1 |>
serocalculator:::plot_curve_params_one_ab(
log_y = FALSE
) +
xlim(0, 100) +
theme_minimal() +
geom_vline(
aes(
xintercept = curve1$t1,
col = "t1"
)
) +

geom_hline(
aes(
yintercept = curve1$y0,
col = "y0"
)
) +

geom_hline(
aes(
yintercept = curve1$y1,
col = "y1"
)
) +
geom_point(
data = curve1,
aes(
x = t1,
y = y1,
col = "(t1,y1)"
)
) +
theme(legend.position = "bottom") +
labs(col = "")

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

Files with missing lines Coverage Δ
R/plot_curve_params_one_ab.R 93.75% <100.00%> (ø)

github-actions bot added a commit that referenced this pull request Mar 26, 2026
@kristinawlai
Copy link
Copy Markdown
Collaborator

@copilot plot_curve_params_one_ab() is an older function. Please replace with an autoplot method for curve params in the methodology.qmd.

Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 26, 2026

@kristinawlai The model claude-sonnet-4.6 is not available for your account. This can happen if the model was disabled by your organization's policy or if your Copilot plan doesn't include access to it.

You can try again without specifying a model (just @copilot) to use the default, or choose a different model from the model picker.

If you want to contact GitHub about this error, please mention the following identifier so they can better serve you: 02f103ff-ee32-404e-ae63-0576213ad7d5

@UCD-SERG UCD-SERG deleted a comment from Copilot AI Mar 26, 2026
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 26, 2026

@kristinawlai The model claude-sonnet-4.6 is not available for your account. This can happen if the model was disabled by your organization's policy or if your Copilot plan doesn't include access to it.

You can try again without specifying a model (just @copilot) to use the default, or choose a different model from the model picker.

If you want to contact GitHub about this error, please mention the following identifier so they can better serve you: 02f103ff-ee32-404e-ae63-0576213ad7d5

@UCD-SERG UCD-SERG deleted a comment from Copilot AI Mar 26, 2026
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 26, 2026

@kristinawlai The model claude-sonnet-4.6 is not available for your account. This can happen if the model was disabled by your organization's policy or if your Copilot plan doesn't include access to it.

You can try again without specifying a model (just @copilot) to use the default, or choose a different model from the model picker.

If you want to contact GitHub about this error, please mention the following identifier so they can better serve you: 02f103ff-ee32-404e-ae63-0576213ad7d5

@kristinawlai
Copy link
Copy Markdown
Collaborator

@copilot plot_curve_params_one_ab() is an older function. Please replace with an autoplot method for curve params in the methodology.qmd.

Copilot AI and others added 4 commits March 26, 2026 07:55
Co-authored-by: kristinawlai <57973437+kristinawlai@users.noreply.github.com>
Agent-Logs-Url: https://github.com/UCD-SERG/serocalculator/sessions/45afccbb-8b7c-4847-85e4-06cbb88354e3
Co-authored-by: kristinawlai <57973437+kristinawlai@users.noreply.github.com>
Agent-Logs-Url: https://github.com/UCD-SERG/serocalculator/sessions/45afccbb-8b7c-4847-85e4-06cbb88354e3
Co-authored-by: kristinawlai <57973437+kristinawlai@users.noreply.github.com>
Agent-Logs-Url: https://github.com/UCD-SERG/serocalculator/sessions/45afccbb-8b7c-4847-85e4-06cbb88354e3
Co-authored-by: kristinawlai <57973437+kristinawlai@users.noreply.github.com>
Agent-Logs-Url: https://github.com/UCD-SERG/serocalculator/sessions/45afccbb-8b7c-4847-85e4-06cbb88354e3
Copilot AI changed the title Fix plot_curve_params_one_ab() error when iter values don't start at 1 Use autoplot for curve params in methodology vignette Mar 26, 2026
github-actions bot added a commit that referenced this pull request Mar 26, 2026
@github-actions
Copy link
Copy Markdown
Contributor

📖 https://UCD-SERG.github.io/serocalculator/preview/pr511/
Preview documentation for this PR (at commit 3ef1b3f)

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