Re: [R] Variable scope in functions - best practices

2011-07-25 Thread Dieter Menne
Noah Silverman wrote: > > > I have several "global" variables that I want to change with a given > function. (The variable has a different value after the function is > called.) > > Berend Hasselman wrote: > > > Maybe this helps > > ?`<<-` > It helps to get the job done, but the OP aske

Re: [R] Variable scope in functions - best practices

2011-07-24 Thread Thomas Lumley
On Mon, Jul 25, 2011 at 4:14 AM, Noah Silverman wrote: > Hi, > > I'm working on coding some more complex things in R and have need to break > much of the logic into functions. > > I have several "global" variables that I want to change with a given > function.  (The variable has a different valu

Re: [R] Variable scope in functions - best practices

2011-07-24 Thread Enrico Schumann
-boun...@r-project.org > [mailto:r-help-boun...@r-project.org] Im Auftrag von Noah Silverman > Gesendet: Sonntag, 24. Juli 2011 18:14 > An: r-help@r-project.org > Betreff: [R] Variable scope in functions - best practices > > Hi, > > I'm working on coding some more com

[R] Variable scope in functions - best practices

2011-07-24 Thread Noah Silverman
Hi, I'm working on coding some more complex things in R and have need to break much of the logic into functions. I have several "global" variables that I want to change with a given function. (The variable has a different value after the function is called.) In other languages like C, this is

Re: [R] Variable scope in functions - best practices

2011-07-24 Thread Berend Hasselman
Noah Silverman wrote: > > Hi, > > I'm working on coding some more complex things in R and have need to break > much of the logic into functions. > > I have several "global" variables that I want to change with a given > function. (The variable has a different value after the function is > call

[R] Variable scope in functions - best practices

2011-07-24 Thread Noah Silverman
Hi, I'm working on coding some more complex things in R and have need to break much of the logic into functions. I have several "global" variables that I want to change with a given function. (The variable has a different value after the function is called.) In other languages like C, this is