-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
cbind on tbl_df should return a tbl_df? #779
Comments
We don't have control over what Perhaps we should replace this line :
by this line to make a
|
@romainfrancois can you please make that change? Ideally we'd preserve the input class, but it's hard to know what to do if you have a mix of tbl df's and data frames |
Thanks for responding so promptly. |
Actually So, for consistency, cbind.tbl_df and friends could produce a tbl_df when all arguments are tbl_dfs, and a data.frame otherwise? |
@lionelgit have you read the dispatch section in help? It's not standard S3 dispatch, and I'm pretty sure it won't work when you have a mix of tbl dfs and data frames. But I'm happy to be proved wrong |
Indeed, I didn't know this subtlety. Still, it may make sense to have a cbind.tbl_df method to produce a tbl_df when all arguments are tbl_df. |
I'll just comment here instead of opening a new issue, as this is likely a small thing.
|
👍 to this thread and proposed enhancement. What @steromano said: when I supply two |
Now it's always making a |
Not sure if this is a feature or a bug - if I cbind two separate tbl_df objects, I expected the result to also be a tbl_df rather than having to cast it myself.
The text was updated successfully, but these errors were encountered: