Re: [R] assigment operator question

2012-04-08 Thread Thomas Lumley
On Sun, Apr 8, 2012 at 11:57 AM, Duncan Murdoch wrote: > On 12-04-07 4:51 PM, Henrik Bengtsson wrote: >> >> On Sat, Apr 7, 2012 at 1:30 PM, Mark Heckmann >>  wrote: >>> >>> Hello, >>> >>> using the<<- assignment operator I do not understand why the following >>> does not work. >>> >>> l<<- list()

Re: [R] assigment operator question

2012-04-07 Thread Duncan Murdoch
On 12-04-07 4:51 PM, Henrik Bengtsson wrote: On Sat, Apr 7, 2012 at 1:30 PM, Mark Heckmann wrote: Hello, using the<<- assignment operator I do not understand why the following does not work. l<<- list() l list() l$arg1<<- "test" error in l$arg1<<- "test" : Objekt 'l' not found ?"<<-" says:

Re: [R] assigment operator question

2012-04-07 Thread Gabor Grothendieck
On Sat, Apr 7, 2012 at 5:01 PM, Mark Heckmann wrote: > Thanks! I'll try to stick to that advice! > Maybe there is a better way... Here is what I want: > > I want to save some default settings for a package. > The user can change these using a function similar to par(). > I do not want to use optio

Re: [R] assigment operator question

2012-04-07 Thread Henrik Bengtsson
On Sat, Apr 7, 2012 at 2:01 PM, Mark Heckmann wrote: > Thanks! I'll try to stick to that advice! > Maybe there is a better way... Here is what I want: > > I want to save some default settings for a package. > The user can change these using a function similar to par(). > I do not want to use optio

Re: [R] assigment operator question

2012-04-07 Thread Mark Heckmann
Thanks! I'll try to stick to that advice! Maybe there is a better way... Here is what I want: I want to save some default settings for a package. The user can change these using a function similar to par(). I do not want to use options() here as it will be quite a lot of parameters. I was thinking

Re: [R] assigment operator question

2012-04-07 Thread Henrik Bengtsson
On Sat, Apr 7, 2012 at 1:30 PM, Mark Heckmann wrote: > Hello, > > using the <<- assignment operator I do not understand why the following does > not work. > > l <<- list() > l > list() > l$arg1 <<- "test" > error in l$arg1 <<- "test" : Objekt 'l' not found > > ?"<<-" says:  "The operators <<- and

[R] assigment operator question

2012-04-07 Thread Mark Heckmann
Hello, using the <<- assignment operator I do not understand why the following does not work. l <<- list() l list() l$arg1 <<- "test" error in l$arg1 <<- "test" : Objekt 'l' not found ?"<<-" says: "The operators <<- and ->> cause a search to made through the environment for an existing defini