> -----Original Message-----
> From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
> project.org] On Behalf Of jd6688
> Sent: Tuesday, July 06, 2010 3:49 PM
> To: r-help@r-project.org
> Subject: [R] how to define a function in R
> 
> 
> 1. how to write a R script?
> 2.How to write a SAS like macro/generic process to process multiple
> files by
> using the same funstion in R?
> 
> Thanks in advance

Don't thank me too soon. :-)  Your question is equivalent to me going to SAS-L 
and asking someone to teach me SAS macro language.  You need to provide more 
information about what your task actually is.  Where are these file names that 
you want to process coming from?  What do you want to do with them?

The basic approach would be to put the file names in a list and then pass the 
list items one at a time to your function.  But how to do that really depends 
on what you are trying to do.  You might also read the posting guide listed at 
the bottom of every posting.

Dan

Daniel J. Nordlund
Washington State Department of Social and Health Services
Planning, Performance, and Accountability
Research and Data Analysis Division
Olympia, WA 98504-5204


______________________________________________
R-help@r-project.org 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