1

when I try to create a data report with the package DataMaid and the function makeDataReport, I am always getting some error messages. The code looks like this:

install.packages("dataMaid")
library("dataMaid") 
codebook_data <- read.csv("C:/Users/...,header = TRUE,
                          sep = ";", quote = "\"", dec = ".", na.strings = "")                                   

codebook_data
makeDataReport(codebook_data)

and when I run the code this error message occurs:

pandoc.exe: Cannot decode byte '\xdf': Data.Text.Internal.Encoding.Fusion.streamUtf8: Invalid UTF-8 stream
Error: pandoc document conversion failed with error 1
In addition: Warning messages:
1: In readLines(con, warn = FALSE) :
  invalid input found on input connection 'dataMaid_codebook_data7.Rmd'
2: In knitr::knit(knit_input, knit_output, envir = envir, quiet = quiet) :
  The file "dataMaid_codebook_data7.Rmd" must be encoded in UTF-8. Please see https://yihui.org/en/2018/11/biggest-regret-knitr/ for more info.
3: In readLines(con, warn = FALSE) :
  invalid input found on input connection 'dataMaid_codebook_data7.knit.md`

Does someone know how to deal with such a problem?

  • 1
    Looks like the .Rmd file is not UTF-8 encoded. See https://stackoverflow.com/questions/3710374 for a method of saving the file as UTF-8. – tarleb Jun 10 '20 at 14:33

0 Answers0