Error while using the function tbl_summary()

420 Views Asked by At

I'm trying to use the function "tbl_summary()", but I'm having the problem below, could someone help me, please?

Error in mutate(): ! Problem while computing df_stats = pmap(...). Caused by error in manip_apply_syms(): ! invalid multibyte string at ''

Thank you, Lays.

2

There are 2 best solutions below

0
Euglenagracilis On

This is, imho, not the tbl_summary() problem itself, but the bigger issue. The problem may be caused by some character(s) - probably Unicode - which can arise if the file is produced by software using different encoding system and then imported to R (however I can not be sure without the reprex).

Here is a similar thread: R: invalid multibyte string for instance, you can use Ram Narasimhan's function to find offending character and remove/convert it. Alternatively you may open your file in the text editor and change encoding/delete whitespaces etc..

0
Lisa On

you need to load library(dplyr) library(magrittr) and that's it