Imagine you have an object foo
that you saved as saved.file.rda
as follows:
foo <- \'a\'
save(foo, file=\'saved.file.rda\')
<
well, i do know a function that eliminates the need to do that (i.e., find the name of the object in the R binary file you just loaded)--in other words, you can use this technique to load R binary files instead of 'load':
file_path = "/User/dy/my_R_data/a_data_set.RData"
attach(file_path, pos=2, name=choose_a_name, warn.conflict=T)
'warn.conflicts=T' is the default option
'pos=2' is also the default; "2" refers to the position in your search path. For instance, position 1 is ".GlobalEnv." To get the entire array of search paths, use search(). So you would access the search path for the new object by search()[2]
use 'detach' to remove the object