X-Git-Url: https://code.communitydata.science/cdsc_tex.git/blobdiff_plain/c46fe4b78e38b4a4284f18c844e64cac1a4e4ea1..ce30e1ac617c570564b72a6ab73b143061886b1a:/paper_template/text.Rnw?ds=sidebyside diff --git a/paper_template/text.Rnw b/paper_template/text.Rnw index a58ce91..1f38026 100644 --- a/paper_template/text.Rnw +++ b/paper_template/text.Rnw @@ -10,6 +10,17 @@ \usepackage[utf8]{inputenc} \usepackage{wrapfig} + +<>= +knit_hooks$set(document = function(x) { + sub('\\usepackage[]{color}', +'\\usepackage[usenames,dvipsnames]{color}', x, fixed = TRUE) +}) +opts_chunk$set(fig.path="figures/knitr-") + +source("resources/preamble.R") +@ + \usepackage[T1]{fontenc} \usepackage{textcomp} \usepackage[garamond]{mathdesign} @@ -26,9 +37,7 @@ % \usepackage{endfloat} % import and customize urls -\usepackage[usenames,dvipsnames]{color} \usepackage[breaklinks]{hyperref} - \hypersetup{colorlinks=true, linkcolor=Black, citecolor=Black, filecolor=Blue, urlcolor=Blue, unicode=true} @@ -135,6 +144,15 @@ brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog \citep{989866}. +\begin{table} + \centering +<>= +kable(form.copy, format="latex") +@ +\caption{This is a test table. There are \Sexpr{f(nrow(form.copy))} rows in the table.} +\label{tab:test} +\end{table} + The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over the lazy dog. The quick brown fox jumps over