Fix deprecated dplyr functions in vignette#23
Conversation
Co-authored-by: Ulthran <14882396+Ulthran@users.noreply.github.com>
|
@copilot Tests need to pass. Make sure you can build the vignettes without error before committing. |
Co-authored-by: Ulthran <14882396+Ulthran@users.noreply.github.com>
Fixed both deprecated dplyr functions causing vignette build failures:
The vignettes should now build without errors. The CI workflows are awaiting approval to run. |
There was a problem hiding this comment.
Pull request overview
This pull request fixes a build failure caused by deprecated dplyr functions that are now defunct in newer versions of dplyr. The vignette was failing to rebuild because it used add_rownames(), mutate_each(), and funs(), which were deprecated in dplyr 1.0.0 and 0.7.0 respectively.
Changes:
- Replaced
add_rownames()withtibble::rownames_to_column()in 4 locations - Replaced
mutate_each(funs())withmutate(across())in 2 locations - Added
library(tibble)to vignette setup andtibbleto DESCRIPTION Suggests
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| vignettes/zibr.Rmd | Updated deprecated dplyr functions to modern equivalents and added tibble library import |
| DESCRIPTION | Added tibble package to Suggests field for vignette dependency |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Vignette rebuild fails on deprecated dplyr functions that are now defunct.
Changes
add_rownames()withrownames_to_column()mutate_each(funs())withmutate(across())mutate_each(funs(p.adjust(., "fdr")), -Species)tomutate(across(-Species, ~p.adjust(., "fdr")))library(tibble)to setup chunktibbleto SuggestsDeprecated Functions Fixed
add_rownames()- deprecated in dplyr 1.0.0, replaced withtibble::rownames_to_column()mutate_each()andfuns()- deprecated in dplyr 0.7.0, replaced withmutate()+across()Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.