Importing attributes from excel
Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason
Importing attributes from excel
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?
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13600
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Importing attributes from excel
No, but if you post your files I'm sure we can help out.
Re: Importing attributes from excel
Should I provide an example file instead? This is for making databank updates for IHS markit.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13600
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Importing attributes from excel
Whatever you're comfortable with.
Re: Importing attributes from excel
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
Thanks
- Attachments
-
- AG_Pricing_Bank_update_Test_2016_12.wf1
- (1.49 MiB) Downloaded 313 times
-
- cpwbank_2016_12b.xlsx
- (2.09 MiB) Downloaded 565 times
Re: Importing attributes from excel
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
They key is replicating something similar to Aremos banks that data can digest. Mnemonics, data update and other attributes updated.
Thanks
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13600
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Importing attributes from excel
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
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!
I will send a test file to the data group soon. I think this is what they are hoping to receive.
Thank you again!
Who is online
Users browsing this forum: No registered users and 2 guests
