Re: [Rd] [BioC] Suppress output from getGEO

From: <>
Date: Fri, 29 Jan 2010 22:54:03 +0100 (MET)

some time ago i communicated the same issue to sean, and i'm very glad he has improved the package -- thanks!

i'm purposefully posting to r-devel rather than to bioconductor. i think that download.file could be improved to avoid this sort of spamming output seen previously with getGEO. currently, it prints dots (when it does) in 5 10-packs per line, line after line. instead, it could be repeatedly printing them on the same line, to give it a more progress bar-like look.

the function putdots (src/modules/internet/internet.c:218) is responsible for printing the dots. after each 5x10 bunch of dots, it proceeds to the next line:

    if((i+1) % 50 == 0) REprintf("\n");

but it could instead just swipe the dots and start in the same line again:

    if((i+1) % 50 == 0) REprintf("\r%55s\r", "");

it's ad hoc, of course, and requires some other changes to prevent the progress bar from being rewritten too quickly, e.g., by replacing

    if(guess <= 0) putdots(&ndots, nbytes/1024);


    if(guess <= 0) putdots(&ndots, nbytes/(100*1024));

in lines 427 and 532 in the same file. it's even more ad hoc, but on my machine it works just fine. i have no time to explore whether it generalises to other configurations.

the attached patch was compiled and tested with no issues:

svn diff src/modules/internet/internet.c > internet.diff svn revert src/modules/internet/internet.c patch -p0 < internet.diff
make check # fine

vQ mailing list Received on Fri 29 Jan 2010 - 22:03:59 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Sat 30 Jan 2010 - 16:20:17 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive