-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Properly convert to dataframe and return the df #120
base: main
Are you sure you want to change the base?
Conversation
Used as.data.frame(x) instead of data.frame(x) to handle conversion of tibbles (and other sort of rectangular data). Then at the end of the function added x to the invisible() command, so the actual data could be returned and used in a pipe.
Codecov Report
@@ Coverage Diff @@
## master #120 +/- ##
=========================================
- Coverage 85.83% 76.74% -9.1%
=========================================
Files 25 25
Lines 1737 976 -761
=========================================
- Hits 1491 749 -742
+ Misses 246 227 -19
Continue to review full report at Codecov.
|
Check if data is a data.frame OR is a tibble() to convert for a data.frame before writing.
I updated the PR to check if data is not a data.frame OR is a tibble to convert to data.frame |
Thanks @IdoBar ! This looks good! Would you mind adding some tests in the You can use |
Used as.data.frame(x) instead of data.frame(x) to handle conversion of tibbles (and other sort of rectangular data).
Then at the end of the function added x to the invisible() command, so the actual data could be returned and used in a pipe.