I was seeing the same error messages about the Unicode character, so I knew that somewhere there was a character that wasn't being recognized.
I thought the problem involved the plot text because I didn't really notice the text output, but when I knit the same thing to an HTML document the text output that cisim()
prints had weird symbols in it.
7 % of the random confidence intervals do not contain Var = 1 .
Since those weird symbols showed in the text output, I thought I'd see what happened if I suppressed the text output. The results
chunk option is relevant to text output. You can see important info on Chunk Options here.
results
: ('markup'
; character) takes these possible values
markup
: mark up the results using the output hook, e.g. put results in a special LaTeX environmentasis
: output as-is, i.e., write raw results from R into the output documenthold
: hold all the output pieces and push them to the end of a chunkhide
(orFALSE
): hide results; this option only applies to normal R output (not warnings, messages or errors)
Hiding the text output means the weird symbols aren't printed and, voila, no latex error. I'm guessing there is a way to get latex to print that symbol if we knew what it was but since the same text output is actually on the plot this is a relatively simple way to fix the problem.
You could consider reporting this to the package maintainers (I didn't check if they have an issue tracker) in case they want to look into it further so this doesn't happen to others.
Don't forget to mark you question solved answered (if it has been):