eitsupi opened a new issue, #513:
URL: https://github.com/apache/arrow-nanoarrow/issues/513
Maybe related to #220
I noticed that if we convert nanoarrow_array_stream to data.frame, the
dictionary becomes a character.
``` r
stream <- data.frame(
x = as.factor(letters[1:5]),
y = as.factor(1:5)
) |>
nanoarrow::as_nanoarrow_array_stream()
stream
#> <nanoarrow_array_stream struct<x: dictionary(int32)<string>, y:
dictionary(int32)<string>>>
#> $ get_schema:function ()
#> $ get_next :function (schema = x$get_schema(), validate = TRUE)
#> $ release :function ()
```
``` r
stream |>
tibble::as_tibble()
#> # A tibble: 5 × 2
#> x y
#> <chr> <chr>
#> 1 a 1
#> 2 b 2
#> 3 c 3
#> 4 d 4
#> 5 e 5
```
<sup>Created on 2024-06-09 with [reprex
v2.1.0](https://reprex.tidyverse.org)</sup>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]