[R] another little problem embedding R

Didier Leibovici didier at fmrib.ox.ac.uk
Tue Aug 14 17:04:37 CEST 2001


I was using 
num <-scan("",numeric(0))
in a file to be ran in batch or with R --vanilla <bidon.R

but I don't know how to make it wait for the value ???
i.e. if you do the same typing

19 didier at mace $ R --vanilla

R : Copyright 2001, The R D

> source("bidon.R")
1: 1
2: 33
3: 999
4: 
Read 3 items
> num
[1]   1  33 999
> q()

the "batch" gave
20 didier at mace $ R --vanilla <bidon.R

R : Copyright 2001, The R Development Core Team
Version 1.2.3  (2001-04
> num <- scan("",numeric(0))
1: Read 0 items
> q()

and if you put source("bidon.R) in Runbidon.R
22 didier at mace $ R --vanilla <Runbidon.R
...
> source("bidon.R")
1: Read 0 items
> 
23 didier at mace $ 


Is there any options or variables to change to make it ...wait!
thanks
-- 
  Didier G. Leibovici    didier at fmrib.ox.ac.uk    +44 (0)1865 222 739
Image Analysis Group                          fax:+44 (0)1865 222 717
Oxford University, Centre For Functional Magnetic Resonance Imaging of
the Brain (FMRIB), John Radcliffe Hospital, Headington, Oxford OX3 9DU,
U.K
http://www.fmrib.ox.ac.uk/~didier/
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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