I wonder about the point of torturing a minimalist text editor with no graphics support (such as Vim into a comprehensive development and visualization enviromment, by invoking several plugins and some very specific workflows. Would it not make more sense to take the interface (modal editing, etc) and wrap it into module that can be easily embedded into several different IDEs, to handle text-specific tasks? That way, there is a fully powered system that can handle all the other tasks that the text editor was never designed to handle!
Oh come on, they're talking about interacting with R. I hope you're aware that R is a simple interpreter and any IDE for R is mostly a window manager that arrangs views on the source code, the REPL, and the graphic display if available. Also: vim isn't vi. Vim isn't minimalist
> Would it not make more sense to take the interface (modal editing, etc) and wrap it into module that can be easily embedded into several different IDEs, to handle text-specific tasks?
Absolutely would. The issue is that this is (evidently) a surprisingly hard problem. I say evidently because I dont know /why/ it is so hard, only that extremely few people have succeeded.
Alternately, would it make sense in R to separate the code and the result instead of a WYSIWYG approach? This is how many work with tools like latex/pdf (among others), edit the source in vim and have a viewer window open next to it.
Or just Emacs in general. Emacs is practically a platform where you pick both language support and UI paradigm as plugins, rather than limiting yourself to one (Vim) or the other (regular IDE).
This article suggest a variety of plugins and then describes a fairly exotic workflow that's alien to my vim brain. I use vim because it's simple, powerful and available almost anywhere. By the time I've installed a bunch of non-standard plugins and learned a set of tool-specific commands, I'm no longer working with vim but some other IDE-type-thing that happens to run inside vim.
As an Emacs/ESS user, I was rather embarrassed/traumatized to see how well Ncm-R completion worked. I’d also somehow missed that there was a usable R LSP implementation around.
As much as I love Vim and R, I think the experience is pointless without embedded graphs. It would be perfect if it was possible to view a graph in a Vim split.
If you want graphs, you're probably not working at the terminal anyway and you're most likely using gvim that integrates nicely with our desktop environment. You can display the R graphics next to the gvim window.
I used TMux to do exactly that. It worked good BUT RStudio is so good.
The enemy of Vim with R is RStudio. It works so well for me I haven't fired up Vim with R in over 3 years. Also I find RStudio Vim to be good enough for me.
> Yes, I know RStudio has Vim keybindings, but it isn’t the real thing. At this point, I’m ruined by Vim.
I say the next step is that we have NeoVim running inside of RStudio. I also think we will have that happening in VSCode a mind bending text editor inside of a text editor.
This setup makes for an interesting blog post, but it goes too far toward being an IDE for my taste. Part of what I like about Vim is that you can customize it to be anything from just text editing—albeit fast and productive text editing—to a full-blown (if hacked-together) IDE.
I think what I would like is a way to embed Vim or Neovim into Rstudio. Rstudio's Vim mode is nice, but I'm too used to my own customizations. It looks like people have experimented with doing this: https://github.com/jalvesaq/Nvim-R/issues/142.
So the suggestion is to use the nvim-r plugin. This plugin uses a custom R lib you have to compile yourself. This may not be possible in every situation. While this is a nice solution for your personal work station, it sometimes isn't in a corporate context.
The argument of "why not use R studio" was not at all convincing for me.
R studio already has vim key bindings, so trying to make vim into rstudio-like seems like spending time on the wrong problem. As in, even if you succeed beyond your wildest dreams you're still not going to compete with R studio.
Things that make Rstudio great that is not so easy to implement include the knitR integration and Rmarkdown integration and embedded graphs and most importantly Rstudio server.