Running python/bash code in Rstudio
This is an example of knitr at it's best, where it allows for multiple language engines. You might consider editing the file for just these cases in VIM, because you can do something fun that is close to what you are asking: select the text and then type:
:'<,'>!python
to execute in python and
:<','>!R --no-save
To execute in R. See the answers to this question for more details.
The above does not solve the use case completely, because the selected text is replaced by the output of the command (starting with the R version etc. in the case of a simple R command). It is possible however, to send the output to a different buffer (read: window) using this vimtip.
The VIM-mode in RStudio is nothing short of excelent (it even supports visual block mode). But it cannot emulate everything and :!python
in RStudio will not work. I often have the document I'm working on open in both RStudio and VIM, and the above might be a reason for you to do the same for Rmd documents with mixed languages.