[R] more question

joerg van den hoff j.van_den_hoff at fz-rossendorf.de
Tue Jan 25 09:53:37 CET 2005


Cuichang Zhao wrote:
> Hello, 
> thank you very much for your help in last email. it is very helpful. right now, i have more questions about my project,
>  
> 1. solve can i remove the NA from a vectors:
> for exmample, if my vector is:
> v <- (NA, 1, 2, 3, 4, 5)

which should read v <- c(NA, 1, 2, 3, 4, 5):



> how can I remove the NA from vector v
>  
v <- v[!is.na(v)]

> 2. how I can get input from the user?

try "?readline"

>  
> 3. can I read more than one data files in one program? and how i can write something to a file

?read.table, ?write.table, ?scan, ?readLines, ?write
>  
> 4. how i can display/output something on the screen?

?print, ?x11, ?plot, ?Devices
>  
> thank you so much
>  
> Best wish
>  
> C-Ming
>  
> Jan 24, 2005
one remark: I personally think it's a bad idea to refer people too 
quickly (with implied reproach) to the manuals (if the manuals are good, 
_anything_ is written down _somewhere_ but it might take substantial 
time to find it).
but at the very least your questions 2.-4. (and the solution to no. 1 is 
not so hard to find either) are so elementary, that you probably have 
not spent a single minute reading the documentation (online help or e.g. 
Introduction to R). and that is in my view not a healthy ratio of "time 
I invested myself to solve the problem" to "time others invest to solve 
my problem".

no offense meant, but really ...

joerg
>  
>  
> 
> 		
> ---------------------------------
> 
> 
> 	[[alternative HTML version deleted]]
> 
> ______________________________________________
> R-help at 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
>




More information about the R-help mailing list