How can I automatically exclude one variable from being saved in the workspace when I quit an R session? The problem is I don't know how to erase a variable once it has been created.
Background: I open a connection called "con" to a database server in my ~/.Rprofile. Obviously, the connection expires when quitting the R session. Unfortunately, the workspace is loaded after ~/.Rprofile is run. So "con" get overwritten by the old workspace. I thought of using .First() or .Last() but as these are functions I don't know how to modify global variables. Ralf ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.