Fix dplyr::as_tibble and dplyr::tbl_df references to use tibble package#197
Fix dplyr::as_tibble and dplyr::tbl_df references to use tibble package#197
Conversation
….R and Run_Mod.R Agent-Logs-Url: https://github.com/ucdavis/serodynamics/sessions/212b7544-cbf9-4137-a367-61fd31be832d Co-authored-by: sschildhauer <165851188+sschildhauer@users.noreply.github.com>
Agent-Logs-Url: https://github.com/ucdavis/serodynamics/sessions/212b7544-cbf9-4137-a367-61fd31be832d Co-authored-by: sschildhauer <165851188+sschildhauer@users.noreply.github.com>
|
📖 https://ucd-serg.github.io/serodynamics/preview/pr197 |
There was a problem hiding this comment.
Pull request overview
This PR cleans up namespace usage and documentation links by switching as_tibble() and tbl_df references from dplyr re-exports/defunct topics to the canonical tibble package, keeping the package’s code and docs aligned with current tidyverse exports.
Changes:
- Updated code to call
tibble::as_tibble()instead ofdplyr::as_tibble()in key post-processing paths. - Updated roxygen links from
[dplyr::tbl_df]to[tibble::tbl_df](and regenerated.Rdoutput accordingly). - Bumped package development version and added a NEWS entry describing the change.
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
R/post_summ.R |
Switches tibble conversion to tibble::as_tibble() for correct namespacing. |
R/Run_Mod.R |
Switches tibble conversion to tibble::as_tibble() and updates roxygen link for sr_model return type. |
R/plot_predicted_curve.R |
Updates roxygen link for dataset parameter type to tibble::tbl_df. |
R/nepal_sees_jags_output.R |
Updates roxygen link in dataset format documentation to tibble::tbl_df. |
R/use_att_names.R |
Updates roxygen link for run_mod() output type to tibble::tbl_df. |
man/run_mod.Rd |
Regenerated docs reflecting tibble::tbl_df link target. |
man/plot_predicted_curve.Rd |
Regenerated docs reflecting tibble::tbl_df link target. |
man/nepal_sees_jags_output.Rd |
Regenerated docs reflecting tibble::tbl_df link target. |
man/use_att_names.Rd |
Regenerated docs reflecting tibble::tbl_df link target. |
NEWS.md |
Documents the namespace correction for as_tibble(). |
DESCRIPTION |
Bumps development version. |
| # Making output a tibble and restructing. | ||
| jags_out <- dplyr::as_tibble(jags_out) |> | ||
| jags_out <- tibble::as_tibble(jags_out) |> | ||
| select(!c("Parameter")) |> |
There was a problem hiding this comment.
Line 183 has a typo ("restructing") and line 184 has extra spacing before the native pipe () |>), which makes the comment/code harder to read and may cause noisy diffs later. Consider correcting the comment (e.g., "restructuring") and normalizing spacing to a single space before |>.
as_tibble()andtbl_dfare exported fromtibble, notdplyr. References todplyr::as_tibble()still work via re-export but are incorrect, and[dplyr::tbl_df]roxygen links now resolve todplyr:defunct.Code
R/post_summ.R,R/Run_Mod.R:dplyr::as_tibble()→tibble::as_tibble()Documentation
R/Run_Mod.R,R/plot_predicted_curve.R,R/nepal_sees_jags_output.R,R/use_att_names.R:[dplyr::tbl_df]→[tibble::tbl_df]in roxygen2 commentstibblewas already inDESCRIPTIONImports; no dependency changes needed.R/as_case_data.R,R/sim_case_data.R, andR/postprocess_jags_output.Ralready used the correcttibble::namespace.