christophergandrud / repmis

Miscellaneous tools for reproducible research with R.
24 stars 9 forks source link

Include functions for workspace cleaning #7

Closed behrica closed 10 years ago

behrica commented 10 years ago

Hi Christopher,

I wrote some functions to clean the workspace of R.

I think this is an important element to achieve reproducible research in R.

The code is very little, see it here:

https://gist.github.com/behrica/864e9424f0b6a6b72db7

The only public function is cleanWS(), which is deleting all objects and unloads all libraries, except the base libraries. This should put the R environment in an "clean" state. It would be useful to have this function in the beginning of each r script or R markdown file, which should be reproducible,

If you would find it useful to get included in your library, let me know and I could send you a pull request.

christophergandrud commented 10 years ago

Sorry for the late reply. I'm away from my computer this week.

This function looks like it could be useful. Feel free to make a pull request to the package so that you will be properly logged by GitHub as a contributor. Or I could do the old fashioned copy and paste way. Just let me know which you prefer.

behrica commented 10 years ago

I just send you a pull request.

christophergandrud commented 10 years ago

Great. I'm take a look in the next few days.

Best Christopher On 23 May 2014 16:31, "behrica" notifications@github.com wrote:

I just send you a pull request.

— Reply to this email directly or view it on GitHubhttps://github.com/christophergandrud/repmis/issues/7#issuecomment-44016342 .

christophergandrud commented 10 years ago

Have you seen the nothing package? It seems to do what you're aiming for: http://blog.r-enthusiasts.com/2014/07/25/a-package-about-nothing/