当前位置:网站首页>If you ask me about R code debugging, I will tell you head, STR, help
If you ask me about R code debugging, I will tell you head, STR, help
2022-07-07 04:50:00 【Mrrunsen】
RMardkown Your code can be more finely controlled when rendering , Such as whether the code is running 、 Whether or not shown 、 How to display 、 Whether the text is output 、 How to output 、 Whether the picture shows 、 How to display and so on .
Detailed information can be referred to Knitr Of Chunk options:https://yihui.org/knitr/options/. Here we mainly show the common format control based on personal experience .
I Code
eval
Whether to run code block , Some code blocks are not running , Just for display .
RMarkdown The code option for is to accept R Variable , Therefore, you can control whether a code block is executed according to specific conditions .
Below RMarkdown On behalf of isShow Is the result greater than 0 To decide whether to execute the second code block .
```{r,include = FASLE}
isShow <- rnorm(1) > 0
```
```{r, eval = isShow}
{eval some code}
```
echo
Whether to show the code block in the result , The code shown below indicates that it is not in the result file ( Such as html file ) Display code in , But it will show the results of the code : Text or pictures, etc .
```{r, echo = FALSE}
{eval some code}
```
tidy
Whether to format when displaying code , If TRUE, Then you can use formatR format R Code : transfer
边栏推荐
- Data security -- 12 -- Analysis of privacy protection
- MySQL数据库(基础篇)
- Can I specify a path in an attribute to map a property in my class to a child property in my JSON?
- Field data acquisition and edge calculation scheme of CNC machine tools
- [line segment tree practice] recent requests + area and retrieval - array modifiable + my schedule I / III
- B站大佬用我的世界搞出卷积神经网络,LeCun转发!爆肝6个月,播放破百万
- mpf2_ Linear programming_ CAPM_ sharpe_ Arbitrage Pricin_ Inversion Gauss Jordan_ Statsmodel_ Pulp_ pLU_ Cholesky_ QR_ Jacobi
- Web3 社区中使用的术语
- 什么是Web3
- Both primary and secondary equipment numbers are 0
猜你喜欢
R language principal component PCA, factor analysis, clustering analysis of regional economy analysis of Chongqing Economic Indicators
Oracle -- 视图与序列
当 Knative 遇见 WebAssembly
On the 110th anniversary of Turing's birth, has the prediction of intelligent machine come true?
How to solve the problem of adding RTSP device to easycvr cluster version and prompting server ID error?
各路行业大佬称赞的跨架构开发“神器”,你get同款了吗?
Depth first traversal template principle of tree and graph
[line segment tree practice] recent requests + area and retrieval - array modifiable + my schedule I / III
Chapter 9 Yunji datacanvas company won the highest honor of the "fifth digital finance innovation competition"!
Break the memory wall with CPU scheme? Learn from PayPal to expand the capacity of aoteng, and the volume of missed fraud transactions can be reduced to 1/30
随机推荐
深耕开发者生态,加速AI产业创新发展 英特尔携众多合作伙伴共聚
计数排序基础思路
Master the secrets of software security testing methods, and pinch the security test report with your hands
【线段树实战】最近的请求次数 + 区域和检索 - 数组可修改+我的日程安排表Ⅰ/Ⅲ
一度辍学的数学差生,获得今年菲尔兹奖
JS form get form & get form elements
Jetson nano配置pytorch深度学习环境//待完善
acwing 843. n-皇后问题
Gpt-3 is a peer review online when it has been submitted for its own research
What if the win11 screenshot key cannot be used? Solution to the failure of win11 screenshot key
MySQL split method usage
What is JVM? What are the purposes of JVM tuning?
Terms used in the Web3 community
System framework of PureMVC
九章云极DataCanvas公司蝉联中国机器学习平台市场TOP 3
How to package the parsed Excel data into objects and write this object set into the database?
Win11截图键无法使用怎么办?Win11截图键无法使用的解决方法
JS also exports Excel
Introduction to the PureMVC series
Station B boss used my world to create convolutional neural network, Lecun forwarding! Burst the liver for 6 months, playing more than one million