Hey Guys, how're things going?
I am writing a program to pull some weather data (by airport code) from a website by modifying the getStock codes a bit. The difference here is that each time this website can only give me 1 year of daily data, and I need 5 years in total. I will have to get one for each of the 50 states in the US, and each pull gives me a date variable. Would it be easier to pull all 50 of them for Year 1 first, and then moving on to Year 2, Year 3, .. and finally somehow use pageappend to combine them together (this is where I am not quite sure how to do), OR to pull the 5-year worth of data for each state and then move on to the next? What would you suggest? Please let me know. Thanks.
Tchaithonov
Data pull + Page Append
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
-
tchaithonov
- Posts: 168
- Joined: Mon Apr 13, 2009 7:39 am
- Location: New York City
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Data pull + Page Append
I think I would create the workfile of the right length (5 years) first, then use the import command to import each of the (250?) website pulls. I don't think it then matters whether you do years then states or states then years.
Glad to see someone using the GetStocks program though :) - still one of my favourites.
Glad to see someone using the GetStocks program though :) - still one of my favourites.
-
tchaithonov
- Posts: 168
- Joined: Mon Apr 13, 2009 7:39 am
- Location: New York City
Re: Data pull + Page Append
Thanks Gareth. The one thing I am most concerned with going down this route is the identification of the dates after each group of pull (by year). You might have the first year done correctly, but what is the correct way to tell eviews that the second group should be appended to the cell 365+1 (first day of the second year)? Besides, the variable names would potentially be a nightmare, since, using getstocks as a reference, variable 1 of year 1 of stock A will have the same name as variable 1 of YEAR 2 of stock A. Perhaps what I can do is to create a page with the full length, then create pages by year (or wfopen + pagestruct) and then append them at the end. What do you think?
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13603
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Data pull + Page Append
If you use the import command, you should be able to get EViews to merge the data into the same series year by year. There should be no need to create new pages etc...
If you have any problems, perhaps you could let me know the website you're getting from (via email if you'd prefer), and I'll see if I can get an example working.
If you have any problems, perhaps you could let me know the website you're getting from (via email if you'd prefer), and I'll see if I can get an example working.
Who is online
Users browsing this forum: No registered users and 2 guests
