Hi, If I type it in the command line I get, as expected: > 1:30 [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 [26] 26 27 28 29 30 > q() Save workspace image? [y/n/c]: n If I create a program 02e451444d6a46acf551996579092c911b90aa8e.R and run it I get R : Copyright 2006, The R Foundation for Statistical Computing Version 2.3.0 (2006-04-24) > source("02e451444d6a46acf551996579092c911b90aa8e.R") Save workspace image? [y/n/c]: n mars:/srv/www/htdocs/mediawiki/teachwiki/Rfiles # more 02e451444d6a46acf551996579092c911b90aa8e.R rfiles<-"/srv/www/htdocs/mediawiki/teachwiki/Rfiles" 1:30 q() No output from 1:30 to the screen. Any idea what I do wrong ? Thanks Sigbert
G'day Sigbert,>>>>> "SK" == Sigbert Klinke <sigbert at wiwi.hu-berlin.de> writes:SK> Hi, If I type it in the command line I get, as expected: >> 1:30 SK> [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 SK> 23 24 25 [26] 26 27 28 29 30 >> q() SK> Save workspace image? [y/n/c]: n SK> If I create a program SK> 02e451444d6a46acf551996579092c911b90aa8e.R and run it I get SK> R : Copyright 2006, The R Foundation for Statistical Computing SK> Version 2.3.0 (2006-04-24) >> source("02e451444d6a46acf551996579092c911b90aa8e.R") SK> Save workspace image? [y/n/c]: n SK> mars:/srv/www/htdocs/mediawiki/teachwiki/Rfiles # more SK> 02e451444d6a46acf551996579092c911b90aa8e.R SK> rfiles<-"/srv/www/htdocs/mediawiki/teachwiki/Rfiles" 1:30 q() SK> No output from 1:30 to the screen. Any idea what I do wrong ? Autoprint of objects is only enabled on the command line, on all other levels you have to explictly call the print() command. So your script should be: print(1:30) q() BTW, interesting name for the file. How do you select that one? ;-) Cheers, Berwin PS: I heard rumours that Wiwi had HU-Berlin was using R instead of XploRe for some tasks..... Slowly I start to believe it... :-)) ========================== Full address ===========================Berwin A Turlach Tel.: +61 (8) 6488 3338 (secr) School of Mathematics and Statistics +61 (8) 6488 3383 (self) The University of Western Australia FAX : +61 (8) 6488 1028 35 Stirling Highway Crawley WA 6009 e-mail: berwin at maths.uwa.edu.au Australia http://www.maths.uwa.edu.au/~berwin
Sigbert Klinke <sigbert at wiwi.hu-berlin.de> writes:> Hi, > > If I type it in the command line I get, as expected: > > > 1:30 > [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 > 23 24 25 > [26] 26 27 28 29 30 > > q() > Save workspace image? [y/n/c]: n > > If I create a program 02e451444d6a46acf551996579092c911b90aa8e.R and run > it I get > > R : Copyright 2006, The R Foundation for Statistical Computing > Version 2.3.0 (2006-04-24) > > source("02e451444d6a46acf551996579092c911b90aa8e.R") > Save workspace image? [y/n/c]: n > > mars:/srv/www/htdocs/mediawiki/teachwiki/Rfiles # more > 02e451444d6a46acf551996579092c911b90aa8e.R > rfiles<-"/srv/www/htdocs/mediawiki/teachwiki/Rfiles" > 1:30 > q() > > No output from 1:30 to the screen. Any idea what I do wrong ?Not reading the help file? (Try source(...., echo=TRUE)) -- O__ ---- Peter Dalgaard ?ster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907