Error(s) in re-building vignettes:
  ...
--- re-building ‘MPSEM.Rnw’ using knitr
Warning in (if (grepl("\\.[Rr]md$", file)) knit2html_v1 else if (grepl("\\.[Rr]rst$",  :
  The file "MPSEM.Rnw" should be encoded in UTF-8. Now I will try to read it with the system native encoding (which may not be correct). We will only support UTF-8 in the near future. Please see https://yihui.name/en/2018/11/biggest-regret-knitr/ for more info.
Warning in grep("^\\s*\\\\(usepackage(\\[.*\\])?\\{Sweave|SweaveInput\\{|SweaveOpts\\{)",  :
  input string 22 is invalid in this locale
Warning in grep("^<<.*\\b(echo|eval|split|include)\\s*=\\s*(true|false)\\b.*>>=",  :
  input string 22 is invalid in this locale
Warning in grep("^<<.*\\bresults\\s*=\\s*(tex|verbatim|hide)\\b.*>>=", x) :
  input string 22 is invalid in this locale
Warning in grep("^<<.*\\b(fig|pdf|eps|jpeg|png|tikz)\\s*=\\s*(true|false|T|F).*>>=",  :
  input string 22 is invalid in this locale
Warning in grep("^<<.*([, ])(width|height)\\s*=\\s*(\\d+).*>>=", x) :
  input string 22 is invalid in this locale
Warning in grep("^<<.*\\b(keep.source|print|term|prefix)\\s*=\\s*(true|false|T|F).*>>=",  :
  input string 22 is invalid in this locale
Warning in grep(db, input) : input string 22 is invalid in this locale
Warning in grep(hb, input) : input string 22 is invalid in this locale
Warning in grep("^\\\\bibliography.+", input, value = TRUE) :
  input string 22 is invalid in this locale
Warning in grepl(chunk.begin, lines) :
  input string 22 is invalid in this locale
Warning in grepl(chunk.end, lines) :
  input string 22 is invalid in this locale
Warning in grepl(inline.comment, input) :
  input string 22 is invalid in this locale
Warning in grep(b, doc) : input string 1 is invalid in this locale
Error: processing vignette 'MPSEM.Rnw' failed with diagnostics:
Running 'texi2dvi' on 'MPSEM.tex' failed.
LaTeX errors:
! LaTeX Error: Environment knitrout undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.68 \definecolor
                 {shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}\begin...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.68 ...hadecolor}{rgb}{0.969, 0.969, 0.969}\color
                                                  {fgcolor}\begin{kframe}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! LaTeX Error: Environment kframe undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: Environment alltt undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.70 \hlkwd
           {library}\hlstd{(MPSEM)}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.70 \hlkwd{library}\hlstd
                          {(MPSEM)}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! LaTeX Error: \begin{document} ended by \end{alltt}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.74 {\ttfamily\noindent\itshape\color
                                      {messagecolor}{\#\# Loading required p...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.76 {\ttfamily\noindent\itshape\color
                                      {messagecolor}{\#\# Loading required p...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! LaTeX Error: \begin{document} ended by \end{kframe}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: \begin{document} ended by \end{knitrout}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: Environment knitrout undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.86 \definecolor
                 {shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}\begin...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.86 ...hadecolor}{rgb}{0.969, 0.969, 0.969}\color
                                                  {fgcolor}\begin{kframe}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! LaTeX Error: Environment kframe undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: Environment alltt undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.88 \hlkwd
           {data}\hlstd{(perissodactyla,}\hlkwc{package}\hlstd{=}\hlstr{"cap...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.88 \hlkwd{data}\hlstd
                       {(perissodactyla,}\hlkwc{package}\hlstd{=}\hlstr{"cap...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.88 \hlkwd{data}\hlstd{(perissodactyla,}\hlkwc
                                               {package}\hlstd{=}\hlstr{"cap...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.88 ...std{(perissodactyla,}\hlkwc{package}\hlstd
                                                  {=}\hlstr{"caper"}\hlstd{)}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.88 ...ssodactyla,}\hlkwc{package}\hlstd{=}\hlstr
                                                  {"caper"}\hlstd{)}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.88 ...kwc{package}\hlstd{=}\hlstr{"caper"}\hlstd
                                                  {)}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! LaTeX Error: \begin{document} ended by \end{alltt}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: \begin{document} ended by \end{kframe}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: \begin{document} ended by \end{knitrout}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! LaTeX Error: Environment knitrout undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.98 \definecolor
                 {shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.98 ...hadecolor}{rgb}{0.969, 0.969, 0.969}\color
                                                  {fgcolor}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.99 \includegraphics
                     [width=\maxwidth]{figure/plot_phylogeny-1}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.99 \includegraphics[width=\maxwidth
                                     ]{figure/plot_phylogeny-1}
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Missing $ inserted.
<inserted text> 
                $
l.99 ...ludegraphics[width=\maxwidth]{figure/plot_
                                                  phylogeny-1}
! Extra }, or forgotten $.
l.99 ...[width=\maxwidth]{figure/plot_phylogeny-1}
                                                  
I've deleted a group-closing symbol because it seems to be
spurious, as in `$x}$'. But perhaps the } is legitimate and
! Missing $ inserted.
<inserted text> 
                $
l.100 
      
! LaTeX Error: \begin{document} ended by \end{knitrout}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Missing } inserted.
<inserted text> 
                }
l.101 \end{knitrout}
                    
! LaTeX Error: Environment knitrout undefined.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Undefined control sequence.
l.148 \definecolor
                  {shadecolor}{rgb}{0.969, 0.969, 0.969}\color{fgcolor}\begi...
The control sequence at the end of the top line
of your error message was never \def'ed. If you have
! Undefined control sequence.
l.148 ...adecolor}{rgb}{0.969, 0.969, 0.969}\color
                                                  {fgco
--- failed re-building ‘MPSEM.Rnw’

SUMMARY: processing the following file failed:
  ‘MPSEM.Rnw’

Error: Vignette re-building failed.
Execution halted