Hi, I'm a new R's user. I am using "faq" and "An Introdution to R" to learn. My main problem for start the learning is: how to save my result in a output file? I has used the sink CMD or $ R > [output file], but the commands go to file and can't to be read in Linux Terminal. The workspace saved at the end of section save only commands and dont save results. Anybody can help-me?? Thank you Inte mais Ronaldo -- //|\\ #******************************************* ( ? ? ) #Ronaldo Reis J?nior V #ESALQ/USP - Entomologia, Caixa Postal - 09 / l \ #13418-900 Piracicaba - SP /(lin)\ #Fone: 19-429-4199 r.229 /(linux)\ #crysopa at insecta.ufv.br / (linux) \#crysopa at terra.com.br | ICQ#: 5692561 ( x ) #******************************************* _/ \_ Powered by Conectiva Linux 6.0 D+:) -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
"Ronaldo Reis Jr." <crysopa at terra.com.br> writes:> I'm a new R's user. I am using "faq" and "An Introdution to R" to > learn. My main problem for start the learning is: how to save my > result in a output file?> I has used the sink CMD or $ R > [output file], but the commands go to file > and can't to be read in Linux Terminal. The workspace saved at the end of > section save only commands and dont save results.Many people using R under Linux find that the ESS package for emacs provides the most convenient way of running R. This may not be the best advice to a newcomer because learning to use emacs and ess is not trivial. Once you do learn, however, these tools are not something you would want to be without. If you run R within an Emacs buffer using ESS you have the complete transcript of your session available to you at all times. -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
> Hi, > I'm a new R's user. I am using "faq" and "An Introdution to R" to learn. > My main problem for start the learning is: how to save my result in a output > file? > I has used the sink CMD or $ R > [output file], but the commands go to file > and can't to be read in Linux Terminal. The workspace saved at the end of > section save only commands and dont save results. > Anybody can help-me?? > Thank you > Inte mais > Ronaldo>From an R user (who is very far from being an expert!): I use"cut-&-paste" (I paste into a text editor (emacs). I find this very convenient as it allows me to be selective. I hope this helps. Rashid Nassar -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
Em Quarta 17 Janeiro 2001 19:45, Ronaldo Reis Jr. escreveu:> Hi, > I''m a new R''s user. I am using "faq" and "An Introdution to R" to learn. > My main problem for start the learning is: how to save my result in a > output file? > I has used the sink CMD or $ R > [output file], but the commands go to file > and can''t to be read in Linux Terminal. The workspace saved at the end of > section save only commands and dont save results. > Anybody can help-me?? > Thank you > Inte mais > RonaldoFor save all commands and results in a terminal (LINUX). script Script started on Sat Jan 20 14:27:21 2001 [ronaldo at localhost Rwork]$ R R : Copyright 2000, The R Development Core Team Version 1.1.1 (August 15, 2000) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type "?license" or "?licence" for distribution details. R is a collaborative project with many contributors. Type "?contributors" for a list. Type "demo()" for some demos, "help()" for on-line help, or "help.start()" for a HTML browser interface to help. Type "q()" to quit R. [Previously saved workspace restored]> demo() m nlm)demo(nlm) ---- ~~~ Type <Return> to start :> theta <- function(x1, x2) {if (x1 > 0) return((0.5/pi) * atan(x2/x1)) else return((0.5/pi) * atan(x2/x1) + 0.5) }> f <- function(x) {f1 <- 10 * (x[3] - 10 * theta(x[1], x[2])) f2 <- 10 * (sqrt(x[1]^2 + x[2]^2) - 1) f3 <- x[3] return(f1^2 + f2^2 + f3^2) }> x <- seq(-1, 2, len = 50)> y <- seq(-1, 1, len = 50)> z <- apply(as.matrix(expand.grid(x, y)), 1, function(x) f(c(x,0)))> contour(x, y, matrix(log10(z), 50, 50))> nlm(f, c(-1, 0, 0), hessian = TRUE, print = 0)$minimum [1] 1.238337e-14 $estimate [1] 1.000000e-00 3.071555e-09 -6.063119e-09 $gradient [1] -3.756314e-07 3.486019e-06 -2.202456e-06 $hessian [,1] [,2] [,3] [1,] 2.000000e+02 -0.04065842 9.776087e-07 [2,] -4.065842e-02 506.60589960 -3.183099e+02 [3,] 9.776087e-07 -318.30988572 2.020000e+02 $code [1] 2 $iterations [1] 27 .. .. ..> q()Save workspace image? [y/n/c]: n [ronaldo at localhost Rwork]$ exit exit Script conclu?do em Sat Jan 20 14:28:13 2001 All terminal''s command will be save in a file named typescript by Inte mais Ronaldo -- //|\\ #******************************************* ( ? ? ) #Ronaldo Reis J?nior V #ESALQ/USP - Entomologia, Caixa Postal - 09 / l \ #13418-900 Piracicaba - SP /(lin)\ #Fone: 19-429-4199 r.229 /(linux)\ #crysopa at insecta.ufv.br / (linux) \#crysopa at terra.com.br | ICQ#: 5692561 ( x ) #******************************************* _/ \_ Powered by Conectiva Linux 6.0 D+:) -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- 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 _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._