[ 
https://issues.apache.org/jira/browse/ARROW-18250?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Nicola Crane updated ARROW-18250:
---------------------------------
    Summary: [R][C++]  mutate(x2=x %>% str_replace('^ s*$',NA_character_)) Does 
not replicate behaviour of R  (was: [R]  mutate(x2=x %>% str_replace('^ 
s*$',NA_character_)) Does not replicate behaviour of R)

> [R][C++]  mutate(x2=x %>% str_replace('^ s*$',NA_character_)) Does not 
> replicate behaviour of R
> -----------------------------------------------------------------------------------------------
>
>                 Key: ARROW-18250
>                 URL: https://issues.apache.org/jira/browse/ARROW-18250
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: C++, R
>            Reporter: Lucas Mation
>            Priority: Critical
>
> {code:r}
> q <- data.table(x=c('','1','2'))
> q %>% write_dataset('q')
> #in R
> q %>% mutate(x2=x %>% str_replace('^
> s*$',NA_character_))
>    x   x2
> 1:   <NA>
> 2: 1    1
> 3: 2    2
> #in arrow
> q2 <- 'q' %>% open_dataset %>% mutate(x2=x %>% str_replace('^
> s*$',NA_character_)) %>% collect
> q2
>    x x2
> 1:     
> 2: 1  1
> 3: 2  2
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to