Possible to use RStudio in Windows but run R in WSL Ubuntu?

Basically, as the title says. I have installed an older version of RStudio Desktop in WSL and run it through X11 with MobaXTerm. It has worked pretty well for some time, but has started to get flaky.

Apparently, RStudio has no intent to support using RStudio in WSL.

So, is there some weird way I could have RStudio Desktop in Windows connect to an R kernel in WSL?


Out of curiosity, what is the benefit of running the RStudio in WSL (compared to regular Ubuntu / whatever? installation)
At first glance it seems to only add complexity, but I am sure I am missing something...

WSL allows me to work in linux simultaneously with windows without having to run a VM or some such thing. Also, I can easily share files back and forth. It's really super amazing for all sorts of development, and I highly recommend it. I prefer to use MobaXTerm which has an integrated, optimized X server, so I can use GUI applications when I need to. This is how I run RStudio Server, and it for the most part works excellently. I have the sweetness of the linux command line and RStudio all at once. I also use Conda environments for my R packages (etc.). It's really a great setup, and tons of developers and data scientists are using it. Unfortunately, RStudio doesn't seem to want to support it.

1 Like

Oki, thanks for the clarification. I have combined the sweetness of Linux command line with RStudio by running both on an Ubuntu laptop.

Yet sometimes, usually on dark and stormy nights, I do miss the comfort of MS Office of Windows environment. Especially when collaborating with others - this might be an option to have it both ways.

It's not that we don't want to support it, it's that we lack the time and resources to support WSL (especially since it's still a moving target and things appear to break and shift under our feet even when we do make an attempt to support it with new versions of Windows / WSL).

Hopefully, this will change in the future.


This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.