Skip to content
Prev 19345 / 63424 Next

SaveImage, LazyLoad, S4 and all that {was "install.R ... files"}

My understanding, and John or others may correct that, is that you need 
SaveImage if you want to have the class hierarchy and generic functions, 
plus associated methods all created and saved at build time. This is 
basically a sort of compilation step, and IMHO, should always be done 
since it only needs to be done once, rather than every time a package is 
loaded. Note that attaching your methods to other people's generics has 
to happen at load time, since you won't necessarily know where they are 
or even what they are until then (using an import directive may 
alleviate some of those issues but I have not tested just what does and 
does not work currently).

I hope that LazyLoad does what it says it does, that is dissociates the 
value from the symbol in such a way that the value lives on disk until 
it is wanted, but the symbol is available at package load time. I do not 
see how this relates to precomputing an image, and would not be very 
happy if the two ideas became one, they really are different and can be 
used to solve very different problems.

best wishes
  Robert
Prof Brian Ripley wrote: