#LyX 2.0 created this file. For more info see http://www.lyx.org/
\lyxformat 413
\begin_document
\begin_header
\textclass article
\begin_preamble
% \VignetteIndexEntry{An Introduction to knitr}
% \VignetteEngine{knitr}
\end_preamble
\use_default_options true
\begin_modules
knitr
\end_modules
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding default
\fontencoding global
\font_roman palatino
\font_sans lmss
\font_typewriter lmtt
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100

\graphics default
\default_output_format default
\output_sync 0
\bibtex_command default
\index_command default
\paperfontsize default
\spacing single
\use_hyperref false
\papersize default
\use_geometry true
\use_amsmath 1
\use_esint 1
\use_mhchem 1
\use_mathdots 1
\cite_engine natbib_authoryear
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\use_refstyle 0
\index Index
\shortcut idx
\color #008000
\end_index
\leftmargin 2.5cm
\topmargin 2.5cm
\rightmargin 2.5cm
\bottommargin 2.5cm
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\paragraph_indentation default
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header

\begin_body

\begin_layout Title
An Introduction to knitr
\end_layout

\begin_layout Author
Yihui Xie
\end_layout

\begin_layout Standard
The 
\series bold
knitr
\series default
 package 
\begin_inset CommandInset citation
LatexCommand citep
key "R-knitr"

\end_inset

 is an alternative tool to Sweave based on a different design with more
 features.
 This document is not the real vignette, but only serves as a placeholder
 to guide you to the real manuals of this package.
 You can find them in the package website: 
\begin_inset Flex URL
status collapsed

\begin_layout Plain Layout

http://yihui.name/knitr
\end_layout

\end_inset


\begin_inset Foot
status open

\begin_layout Plain Layout
e.g.
 the main manual: 
\begin_inset Flex URL
status collapsed

\begin_layout Plain Layout

https://bitbucket.org/stat/knitr/downloads/knitr-manual.pdf
\end_layout

\end_inset

 and the graphics manual: 
\begin_inset Flex URL
status collapsed

\begin_layout Plain Layout

https://bitbucket.org/stat/knitr/downloads/knitr-graphics.pdf
\end_layout

\end_inset


\end_layout

\end_inset

, and remember to read the help pages of functions in this package.
\end_layout

\begin_layout Standard
Anyway, here is a code chunk that shows you can compile vignettes with 
\series bold
knitr
\series default
 as well by using a proper 
\family sans
Makefile
\family default
 (see 
\begin_inset Flex URL
status collapsed

\begin_layout Plain Layout

http://yihui.name/knitr/demo/vignette/
\end_layout

\end_inset

):
\end_layout

\begin_layout Standard
\begin_inset ERT
status open

\begin_layout Plain Layout

<<show-off>>=
\end_layout

\begin_layout Plain Layout

rnorm(5)
\end_layout

\begin_layout Plain Layout

df=data.frame(y=rnorm(100), x=1:100)
\end_layout

\begin_layout Plain Layout

summary(lm(y~x, data=df))
\end_layout

\begin_layout Plain Layout

@
\end_layout

\end_inset


\end_layout

\begin_layout Standard
\begin_inset CommandInset bibtex
LatexCommand bibtex
bibfiles "../examples/knitr-packages"
options "jss"

\end_inset


\end_layout

\end_body
\end_document
