Hi

cat("\n","Enter x","\n") # prompt
y<-scan(n=1)

prompts for user imput and scans 1 line from console.

HTH
Petr



On 4 Aug 2006 at 17:06, chiya sharma wrote:

Date sent:              Fri, 4 Aug 2006 17:06:38 +0530
From:                   "chiya sharma" <[EMAIL PROTECTED]>
To:                     r-help@stat.math.ethz.ch
Subject:                [R] User input from keyboard

> Dear All,
> 
>  Can anybody tell me the syntax for "User input from keyboard" in R. I
>  mean
> to say that if I run the program it should ask "Please enter the date"
> at the begining of the program. I am using R-2.2.1 for windows.
> 
> Any help will be greatly appreciated.
> thanks in advance.
> 
> Regards,
> Chiya
> 
>  [[alternative HTML version deleted]]
> 
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html and provide commented,
> minimal, self-contained, reproducible code.

Petr Pikal
[EMAIL PROTECTED]

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to