[R] question about attaching data

Pancho Mulongeni p.mulongeni at namibia.pharmaccess.org
Thu Mar 28 09:36:19 CET 2013


Hi I just would like to know,
When I have a dataframe, like this one called 'dummy'
And I attach it.
Then I run my code. 
I then update the dataframe by making changes and I still call it 'dummy'.
I run my code again.
Now dummy is at position 1 and position 2 of the search path and if I run the code again, with another version of 'dummy' it updates and eventually my search path looks like this
[1] ".GlobalEnv"        "dummy"             "dummy"            
 [4] "dummy"             "package:stats"     "package:graphics" 
 [7] "package:grDevices" "package:datasets"  "package:rcom"     
[10] "package:rscproxy"  "package:utils"     "package:methods"  
[13] "RExcelEnv"         "Autoloads"         "package:base"

I get the correct data, as the previous versions of dummy are 'masked from the search path'. What stops me from continuing this process ad infinitum?
What's the use of detaching dummy using detach()?
Thanks


Pancho Mulongeni
Research Assistant
PharmAccess Foundation
1 Fouché Street
Windhoek West
Windhoek
Namibia
 
Tel:   +264 61 419 000
Fax:  +264 61 419 001/2
Mob: +264 81 4456 286



More information about the R-help mailing list