[R] Programcode and data in the same textfile
Peter Dalgaard BSA
p.dalgaard at biostat.ku.dk
Mon Jun 16 18:01:17 CEST 2003
Gabor Grothendieck <ggrothendieck at volcanomail.com> writes:
> It would be even cleaner just to use stdin() but unfortunately
> stdin() does not work in sourced files (bug?).
Design issue. Source()'d files are checked for syntactical validity
before they are run. Saves the user from some embarrassments, although
far from all. Consequentially, it cannot allow you to include lines
that don't look like valid R.
(Another aspect of the source() design is that it cannot deal with a
potentially infinite stream of R commands. If we ever get around to
implementing a setReader() mechanism, then the embedded-data issue
might be solved simultaneously.)
--
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
More information about the R-help
mailing list