Skip to content
Prev 276387 / 398506 Next

Reading parameters from dataframe and loading as objects

Hi,

assign is your friend here:
apply(data,1,function(x)assign(x[1],x[2],envir = .GlobalEnv))

As a note, you probably don't want to use data as a variable because it overwrites the data function, leading to unwanted side-effects if you ever use it.

Cheers,

Fran?ois Pepin
Scientist
 
Sequenta, Inc.
400 E. Jamie Court, Suite 301
South San Francisco, CA 94080
 
650 243 3929 p
 
francois.pepin at sequentainc.com
www.sequentainc.com
 
The contents of this e-mail message and any attachments are intended solely for the addressee(s) named in this message.  This communication is intended to be and to remain confidential and may be subject to applicable attorney/client and/or work product privileges.  If you are not the intended recipient of this message, or if this message has been addressed to you in error, please immediately alert the sender by reply e-mail and then delete this message and its attachments.  Do not deliver, distribute or copy this message and/or any attachments and if you are not the intended recipient, do not disclose the contents or take any action in reliance upon the information contained in this communication or any attachments.
On Nov 3, 2011, at 23:24 , Aher wrote: