r - xaringan code output same style as bookdown
问题描述
Is it possible to customize xaringan to have the code output bookdown style, that is, code and output in the same block?. For instance, see this:
library(tidyverse)
#> ── Attaching packages ────────────────────────────────── tidyverse 1.2.1 ──
#> ✔ ggplot2 3.1.0.9000 ✔ purrr 0.2.5
#> ✔ tibble 2.0.0 ✔ dplyr 0.7.8
#> ✔ tidyr 0.8.2 ✔ stringr 1.3.1
#> ✔ readr 1.3.1 ✔ forcats 0.3.0
#> ── Conflicts ───────────────────────────────────── tidyverse_conflicts() ──
#> ✖ dplyr::filter() masks stats::filter()
#> ✖ dplyr::lag() masks stats::lag()
The default style has the code and the output in two different blocks:
解决方案
推荐阅读
- c++ - 为什么这个例子只适用于断点
- python - 当元素包含在变量中时如何从Python中的列表中删除元素
- java - BCrypt 更新库和交互——它会破坏我的登录吗?
- javascript - 如果 ID 尚未定义,则写入 JSON 数据库
- ruby-on-rails - 在 Docker 容器上进行远程调试时,无法使用 Visual Studio 代码中断任何断点
- python - python中的高效空间变化卷积
- linux - 对 bash 脚本中特定命令的特权访问
- c++ - 如何打印数字的所有排列
- java - 如何解决 java.lang.ClassNotFoundException: DocumentException
- python - Django - 表单未更新