Hello,
I have this script which will be invoked as
Rscript a.r < a.r
a.r follows
#!/usr/bin/Rscript --vanilla
f=file("stdin")
while(TRUE){
y=readLines(f,n=1,warn=TRUE)
if(length(y)==0) break else print(y)
}
But it only reads one line from a.r
How can I read line by line from standard input?
Thank you
Saptarshi