Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dev.new() launch to second monitor

Tags:

windows

plot

r

ess

I am wondering if anyone is aware of a way to call dev.new() and have the resulting frame launch to a second monitor by default. I'm running R through ESS under Windows 7. It defaults to upper right corner of my primary monitor.

UPDATE

dev.new(xpos=1930, ypos=65) will launch the plot window to upper left corner of my secondary monitor.

I would still be interested in how to set xpos and ypos under device, either per session, per script, or globally.

like image 230
joeln Avatar asked Oct 30 '22 02:10

joeln


1 Answers

Look at getOption("device") and Sys.getenv("_R_CHECK_SCREEN_DEVICE_"). There should be your device number. I am on linux, so can't say what windowZ call these, but I get a number. If the default one is 1, than if I set it to 2, i get it on the external monitor.

like image 130
mike Avatar answered Nov 15 '22 05:11

mike