Your best data science-y option with weaving documents on the fly is Emacs with org-mode.

Start with one document, insert `#+begin_src` and `#+end_src` blocks; for R for instance use `:session` as an option, and then export your documents to whichever formats you like.

You cannot go much wrong with Emacs. Works everywhere.

Associate Professor of Epidemiology and Environmental Health at the University of Canterbury, New Zealand. Also in: https://refind.com/arinbasu

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store