On Thu, May 6, 2010 at 10:47 PM, Mohan L <l.mohan...@gmail.com> wrote:
>
>
<snip>
>
> I am using source() to run program, like
>
>> source (sample.R)
>
> I want to know how to pass the argument to my sample.R, some this like
>
>> source(sample.R, xxx,FeMale)
>
>  Is it possible? any link will greatly appreciated.

I do not believe that you can pass arguments to source() that you want
to be passed to some function inside of the file or connection being
sourced.  Perhaps turn the contents of the file you are sourcing in
into a function, and then call that function from the command line and
pass the arguments you want to it?

Josh

>
> Thanks & Rg
> Mohan L
>


-- 
Joshua Wiley
Senior in Psychology
University of California, Riverside
http://www.joshuawiley.com/

______________________________________________
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