Skip to content

pause in function execution

2 messages · Fuchs Ira

#
I tried using the command-line and indeed it does not buffer so that,  
for example:

for (i in 1:5) {
print(x)
Sys.sleep(3)  }

does as expected.

However, the following sleeps for 15 seconds and then produces no  
output:

library("quantmod")

for (i in 1:5) {
getQuote("AAPL")
Sys.sleep(3)  }

Why is that?

Thanks.
On Feb 9, 2009, at 8:04 PM, Rolf Turner wrote:

            
#
Oops...forgot to print(getQuote("AAPL").  Sorry.
On Feb 10, 2009, at 10:21 AM, Fuchs Ira wrote: