Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I get my R buffer in emacs to occupy more horizontal space?

Tags:

emacs

r

ess

At the moment when I start up an ESS buffer (with M-x R) I get that the output of my commands only occupies about 60ish characters in column width (particularly when displaying data frames with long column names). I was wondering if there was a simple way to adjust this limit.

like image 717
Palace Chan Avatar asked Sep 20 '12 20:09

Palace Chan


1 Answers

Ben Bolker's comment is correct: options("width"=200) is something I use on a machine with wide monitors.

I am not aware of an environment variable that reports this back to ESS to auto-adjust. It would be a useful addition.

And just like options("width"), a few things are generally useful at startup, so I currently have this on another machine

edd@max:~$ cat .Rprofile
## Example of .Rprofile
options(width=155, digits=6, digits.secs=6)
## AER page vii
options(prompt="R> ")
## Default repo
local({r <- getOption("repos")
       r["CRAN"] <- "http://cran.r-project.org"
       options(repos=r)
})
like image 119
Dirk Eddelbuettel Avatar answered Sep 26 '22 00:09

Dirk Eddelbuettel