Skip to content

Commit

Permalink
Fixed knitting by replacing breaking characters for time being.
Browse files Browse the repository at this point in the history
  • Loading branch information
karthik committed Aug 1, 2013
1 parent 0c24f98 commit 4d548eb
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions ggplot.Rnw
Expand Up @@ -15,8 +15,13 @@ opts_chunk$set(cache=TRUE, message=FALSE)
# smaller font size for chunks
opts_chunk$set(size = 'footnotesize')
options(width = 60)
knit_hooks$set(inline = function(x) {
if (is.numeric(x)) return(knitr:::format_sci(x, 'latex'))
knitr:::hi_latex(x)
})
@


% --------------------------------------------------------------
\begin{document}
\title{Data Visualization with R \& ggplot2}
Expand Down Expand Up @@ -583,7 +588,7 @@ library(ggthemes)
my_custom_plot <- function(df, title = "", ...) {
ggplot(df, ...) +
ggtitle(title) +
whatever geoms() +
whatever_geoms() +
theme(...)
}
@
Expand All @@ -605,11 +610,11 @@ plot1 <- my_custom_plot(dataset1, title = "Figure 1")
\begin{frame}[fragile]
\frametitle{Commonly used scales}
<<scale_list, eval=FALSE, tidy=FALSE>>=
scale_fill_discrete(), scale_colour_discrete()
scale_fill_hue(), scale_color_hue()
scale_fill_manual(), scale_color_manual()
scale_fill_brewer(), scale_color_brewer()
scale_linetype(), scale_shape_manual()
scale_fill_discrete(); scale_colour_discrete()
scale_fill_hue(); scale_color_hue()
scale_fill_manual(); scale_color_manual()
scale_fill_brewer(); scale_color_brewer()
scale_linetype(); scale_shape_manual()
@
\end{frame}

Expand Down

0 comments on commit 4d548eb

Please sign in to comment.