作者热门文章
- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
<<newChunk,echo=FALSE,comment=NA,background=NA>>=
x <- "\\includegraphics[width=\\maxwidth]{figure/Kompetenz1.pdf}"
cat(x)
@
\begin{knitrout}
\definecolor{shadecolor}{rgb}{1, 1, 1}\color{fgcolor}\begin{kframe}
\begin{verbatim}
\includegraphics[width=\maxwidth]{figure/Kompetenz1.pdf}
\end{verbatim}
\end{kframe}
\end{knitrout}
最佳答案
我不确定你为什么首先使用 Knitr。看起来您只是想在您的 latex 文档中包含一个 PDF。为此,我将使用以下命令:
\includepdf[pages=-]{figure/Kompetenz1.pdf}
\includegraphics[width=\maxwidth]{figure/Kompetenz1.pdf}
关于r - 没有 knitrout 和逐字环境的 block 输出,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26400959/
我正在使用 knitr 嵌入 R 代码并输出到我正在编写的教科书中。在我的教科书中,我首先用深灰色背景编写 R 代码,然后在下一个 block 中用浅色背景运行 R 代码。我基本上执行以下操作: >=
knitr Chunk选项 results = "hold"可以把输出放在Chunk Code之后.我想知道如何拆分knitr将代码和输出分 block 成两个不同的 knitrouts可能带有 Co
>= x <- "\\includegraphics[width=\\maxwidth]{figure/Kompetenz1.pdf}" cat(x) @ 如果我在我的 .Rnw 文件中运行这个 r
我是一名优秀的程序员,十分优秀!