https://github.com/yonicd/tidycheckUsage
create tidy output for codetools::checkUsage functions
https://github.com/yonicd/tidycheckUsage
Last synced: 4 months ago
JSON representation
create tidy output for codetools::checkUsage functions
- Host: GitHub
- URL: https://github.com/yonicd/tidycheckUsage
- Owner: yonicd
- License: other
- Created: 2018-05-06T21:57:15.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-11T13:48:22.000Z (about 6 years ago)
- Last Synced: 2024-11-23T11:11:01.564Z (5 months ago)
- Language: R
- Homepage:
- Size: 510 KB
- Stars: 9
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE
Awesome Lists containing this project
- jimsghstars - yonicd/tidycheckUsage - create tidy output for codetools::checkUsage functions (R)
README
---
output: github_document
always_allow_html: yes
---```{r, echo = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "tools/readme/README-"
)
```# tidycheckUsage
When using `magrittr` pipes or `ggplot2` reading the objects that you forgot
to `enquo` is a pain. These functions can be run prior to
`devtools::check` to return a `data.frame` containing all the warnings
created when `check` runs `codetools::checkUsage`. Using this information actionable functions append `rlang` syntax to fix the warnings.## Installation
```{r gh-installation, eval = FALSE}
remotes::install_github('yonicd/tidycheckUsage')```
## Examples
### Installed Packages
```{r}
library(tidycheckUsage)```
```{r,eval=FALSE}
install.packages(c('dplyr'))
``````{r package}
library(dplyr,warn.conflicts = FALSE,quietly = TRUE)knitr::kable(tidycheckUsagePackage('dplyr'))
```### Built Packages
```{r,eval=FALSE}
system('git clone https://github.com/hrbrmstr/slackr.git')
devtools::install('slackr')```
```{r builtpkg,eval=FALSE}
tidycheckUsagePackage('slackr')
```
### Functions in Environment
```{r,eval=FALSE}myfun <- function(x){
ret <- mtcars%>%
mutate(mpg2=mpg*x)
ret <- ret%>%
dplyr::mutate(mpg3=mpg2^2)
}tidycheckUsage(fun = myfun)
```