[R] using "list=" to force evaluation before execution
jim holtman
jholtman at gmail.com
Thu Jan 12 18:02:18 CET 2012
Read the documentation for those two commands and you will see that
'list' is just a parameter to the function. It would have been called
'xyz' and worked the same. The is nothing special about 'list =' in
this context; it is just naming a parameter to the function.
On Thu, Jan 12, 2012 at 11:55 AM, Aditya Bhagwat
<bhagwataditya at gmail.com> wrote:
> Dear all,
>
> I have noticed that the expression 'list =' is sometimes used to tell R to
> evaluate something before executing it.
>
> Two examples:
>
> rm(list=ls())
>
> a = 3
> myVarName = 'a'
> save(list=myVarName, file=...)
>
>
> I was wondering whether there is any documentation on this way of using
> "list". Which is a clearly different use than what ?list talks about, as
> the latter addresses the use of 'list' as a datastructure.
>
> Thanks for your help,
>
> Adi
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at 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.
--
Jim Holtman
Data Munger Guru
What is the problem that you are trying to solve?
Tell me what you want to do, not how you want to do it.
More information about the R-help
mailing list