我刚刚升级到组织9.3.6,现在我的R代码块无法按预期工作。例如,我有这个简单的代码块,
#+BEGIN_SRC R :session
mtcars1 <- mtcars
#+END_SRC
我不希望看到任何输出,因为我将mtcars
保存为mtcars1
,因此R不应返回任何内容。但是,我看到了这个,
print(mtcars1)
为什么?我不希望/不希望看到任何输出,尤其是对于较大的数据帧,因为它会阻塞emacs。
看起来您正在使用组织结构源标头中的默认值:results value
。可以根据具体情况使用
#+begin_src R :session :results output
mtcars1 <- mtcars
#+end_src
或更改您的组织(或ess / R)初始配置中的默认设置
(setq org-babel-default-header-args:R '((:results . "output")))