https://github.com/eachanjohnson/errR
Graceful error handling in R
https://github.com/eachanjohnson/errR
error-handling graceful
Last synced: 4 months ago
JSON representation
Graceful error handling in R
- Host: GitHub
- URL: https://github.com/eachanjohnson/errR
- Owner: eachanjohnson
- License: mit
- Created: 2016-10-06T17:12:09.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-09-09T04:57:15.000Z (over 6 years ago)
- Last Synced: 2024-08-13T07:11:38.383Z (8 months ago)
- Topics: error-handling, graceful
- Language: R
- Size: 10.7 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- jimsghstars - eachanjohnson/errR - Graceful error handling in R (R)
README
[](https://travis-ci.org/eachanjohnson/errR)
# errR
`errR` is a minimal framework which wraps R's `tryCatch` into a system of binary operators to make defensive programming more succinct and readable.## Installation
Not yet on CRAN. Install using `devtools`:
`devtools::install_github('eachanjohnson/errR')`
## Usage
Currently supports two related idioms:`
%except% `
`
%except% `
In an interactive R session, try:
`stop('This is an error!')`
Then compare with:
`stop('This is an error!') %except% print('Error, but continuing anyway')`
See how this compares to:
`stop('This is an error!') %except% print`
## To do
- Handle warnings
- Add `%finally%` operator