-
Notifications
You must be signed in to change notification settings - Fork 3
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
Export functions to read/scan/write data #111
Comments
Related issue: apache/arrow#38456 Personally, I think it would be fine to have more R-like style functions like This would be similar to, for example, Python Polars having something like the |
Why should it be in |
Of course, it doesn't have to be present, but the mere sugar syntax is present in Python Polars. Also, as for |
Of note, in R4.3 (and probably 4.2, I am not sure) the native placeholder > women |> _$weight
[1] 115 117 120 123 126 129 132 135 139 142 146 150 154 159 164 |
If we introduce this kind of functions in |
I think this is not the case in this case. |
The problem with the arrow package is that the function names are inconsistent. |
So far I only exported
sink_*
functions because they don't risk namespace collision with other packages, while exportingwrite_parquet()
orread_parquet()
would conflict witharrow
for example.However, some users do not know the existence of
pl$read_parquet()
andpl$scan_parquet()
, and therefore usearrow::read_parquet()
andas_polars_df()
which is not efficient at all. The goal oftidypolars
is to replace the somewhat confusing (to R users) syntax ofpolars
so that they don't have to deal withpl$
for instance. Therefore, I shouldn't expect them to usepl$scan_parquet()
.The easy solution would be to add the "_polars" suffix for read/write functions (and potentially sink and scan for consistency?), so I would export
read_parquet_polars()
for instance.duckplyr
hasduckplyr_df_from_parquet()
, so one option would be to exportpolars_df_from_parquet()
andpolars_lf_from_parquet()
instead of read and scan.Edit: not a big fan of
polars_lf_from_parquet()
because I like seeing all the options in the autocompletion when I type "write"The text was updated successfully, but these errors were encountered: