Error(s) in re-building vignettes:
  ...
--- re-building ‘momentuHMM.Rnw’ using knitr
momentuHMM 1.4.3 (2018-11-21)
Error in parse(text = code, keep.source = FALSE) : 
  <text>:2:35: unexpected ')'
1: DM$angle = list(mean = ~state2(angleFormula(d, strength = w)), 
2:                 concentration= ~1))
                                     ^
Warning in highr::hilight(x, format, prompt = options$prompt, markup = opts$markup) :
  the syntax of the source code is invalid; the fallback mode is used
Error: processing vignette 'momentuHMM.Rnw' failed with diagnostics:
Running 'texi2dvi' on 'momentuHMM.tex' failed.
LaTeX errors:
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.629 
      
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.641 
      
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.694 
      
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.743 
      
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.841 
      
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.851 
      
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.1053 
       
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.1063 
       
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.1103 
       
! Illegal parameter number in definition of \reserved@a.
<to be read again> 
                    
l.1112 \hlcom{# calculate stationary distribution}
                                                  
! Illegal parameter number in definition of \reserved@b.
<to be read again> 
                   }
l.1112 \hlcom{# calculate stationary distribution}
                                                  
! You can't use `macro parameter character #' in horizontal mode.
<recently read> ##
                  
l.1112 \hlcom{# calculate stationary distribution}
                                                  
! Illegal parameter number in definition of \reserved@a.
<to be read again> 
                    
l.1119 ...m initial locations for each individual}
                                                  
! Illegal parameter number in definition of \reserved@b.
<to be read again> 
                   }
l.1119 ...m initial locations for each individual}
                                                  
! You can't use `macro parameter character #' in horizontal mode.
<recently read> ##
                  
l.1119 ...m initial locations for each individual}
                                                  
! Illegal parameter number in definition of \reserved@a.
<to be read again> 
                    
l.1125 \hlcom{# create centroid data frame}
                                           
! Illegal parameter number in definition of \reserved@b.
<to be read again> 
                   }
l.1125 \hlcom{# create centroid data frame}
                                           
! You can't use `macro parameter character #' in horizontal mode.
<recently read> ##
                  
l.1125 \hlcom{# create centroid data frame}
                                           
! Extra }, or forgotten $.
<recently read> }
                 
l.1126 ...hlkwc{x} \hlstd{= centroidData}\hlopt{$}
                                                  \hlstd{x,} \hlkwc{y} \hlst...
! Missing } inserted.
<inserted text> 
                }
l.1126 ...hlkwc{y} \hlstd{= centroidData}\hlopt{$}
                                                  \hlstd{y)}
! LaTeX Error: \begin{figure} on input line 1088 ended by \end{alltt}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Extra }, or forgotten \endgroup.
\endMakeFramed ...eight \z@ \penalty -100 \egroup 
                                                  \begingroup \fb@put@frame ...
l.1136 \end{kframe}
                   
! Undefined control sequence.
\endkframe ...ip \endMakeFramed \at@end@of@kframe 
                                                  
l.1136 \end{kframe}
                   
! LaTeX Error: \begin{figure} on input line 1088 ended by \end{kframe}.

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

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Missing } inserted.
<inserted text> 
                }
l.1137 \end{knitrout}
                     
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.1350 
       
! LaTeX Error: Not in outer par mode.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Paragraph ended before \@tempa was complete.
<to be read again> 
                   \par 
l.1697 
       
! LaTeX Error: \begin{figure} on input line 1691 ended by \end{document}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! You can't use `\end' in internal vertical mode.
\enddocument ... \endgroup \deadcycles \z@ \@@end 
                                                  
l.1717 \end{document}
                     
! LaTeX Error: \begin{figure} on input line 1691 ended by \end{document}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              
! Emergency stop.
<*> \nonstopmode \input ./momentuHMM.tex
                                        
*** (job aborted, no legal \end found)

!  ==> Fatal error occurred, no output PDF file produced!
--- failed re-building ‘momentuHMM.Rnw’

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

Error: Vignette re-building failed.
Execution halted