I am using ESS in order to stay in Emacs when working with R. Whenever I create a plot a new pop-up appears with the graph. This new window seems to be a part of the R process called inside Emacs. As such the new window is not part of the buffer-list and seems to lie outside the Emacs environment.
Can a new window created by R, containing e.g. graphs called by plot() or respective functions in ggplot2/lattice, be forced to stay inside the Emacs environment? So that the plot is available as a new buffer.
Thanks!
This is unlikely to be the solution you are looking for as it involves turning Emacs into a window manager (works for Linux and MacOS): the package EXWM (Emacs X Window Manager) is a full-featured tiling window manager that turns all X windows into Emacs buffers.
Here is an example of what that would look like (note the R Graphics window on the right which is now an Emacs buffer):
This allows you to use Emacs keybindings, configuration, etc. to all X windows.
This does not exactly answer the OP's question because this goes outside of ESS but it still may be relevant to some because it still relates to using R to generate graphics that can be viewed inside of Emacs.
You can do this using Emacs iPython Notebook (ein). You have to set up Jupyter first but after that it's pretty straightforward and can work with different kernels (R, Python, Julia, etc.). Below is a screenshot
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With