[Fwd: Re: [R] Memory leak in R v1.5.1?] - resolved
Peter Dalgaard BSA
p.dalgaard at biostat.ku.dk
Wed Aug 7 19:10:34 CEST 2002
Jan Meyer <janm at mit.edu> writes:
> Hi,
>
> an attach() call turned out to be my problem (see below).
>
> Thanks everybody for the helpful comments.
>
...
> I still don't fully understand why attach caused the problem. Wouldn't
> attach just place some variables in the environment of the function,
> which is destroyed at the end of the function call?
No, attach() adds things to the search path (and logically, although
not always physically, copies them). This is not reversed when the
function exits. [It is not obvious that it has to work that way, but
currently it does.]
--
O__ ---- Peter Dalgaard Blegdamsvej 3
c/ /'_ --- Dept. of Biostatistics 2200 Cph. N
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list