An open API service indexing awesome lists of open source software.

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

Awesome Lists containing this project

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)

```