Page 1 of 1

Importing attributes from excel

Posted: Tue Jan 10, 2017 11:16 am
by jtb35962
I am attempting to import attributes from Excel. I read that it is possible using importattr, but upon cursory attempts from reading the help options after importing a second work file with potential attributes, I cannot correctly use the command box make it work. This is likely do to my inexperience. Are there any tutorials or example programs to do this?

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 11:20 am
by EViews Gareth
No, but if you post your files I'm sure we can help out.

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 11:27 am
by jtb35962
Should I provide an example file instead? This is for making databank updates for IHS markit.

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 11:49 am
by EViews Gareth
Whatever you're comfortable with.

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 12:08 pm
by jtb35962
I have included a test file and the associated excel. I am not sure that the excel is set up correctly, but it is a start.
Thanks

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 12:16 pm
by jtb35962
I update these and others monthly and even more series quarterly, so I need to replicate the process regularly and on a large scale.
They key is replicating something similar to Aremos banks that data can digest. Mnemonics, data update and other attributes updated.
Thanks

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 1:02 pm
by EViews Gareth
Just using this Excel file:

Code: Select all

'open the data, ignoring the attribute rows wfopen cpwbank_2016_12b.xlsx colhead=5 namepos=first 'open the attribute as a second page pageload(page=attr) cpwbank_2016_12b.xlsx range=sheet2!b1:pe5 byrow colhead=0 names=(name, bank, dataedge, forecastdate, longlabel) 'switch back to data page pageselect cpwbank_2016_12b 'import attributes importattr attr

Re: Importing attributes from excel

Posted: Tue Jan 10, 2017 2:29 pm
by jtb35962
Thank you very much. This looks like it is working and I should be able to replicate this code easily to other properly formatted excel files.
I will send a test file to the data group soon. I think this is what they are hoping to receive.
Thank you again!