tabplace

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason

Katjes
Posts: 58
Joined: Thu Oct 02, 2008 5:46 am

tabplace

Postby Katjes » Thu Jun 06, 2019 6:23 am

Is there a way to loop over a particular number of rows in tabplace, instead of providing the numbers manually. Instead of

Code: Select all

tabplace (tab_new, tab_old, "A14","A14","N14") tabplace (tab_new, tab_old, "A15","A16","N16")
Something like

Code: Select all

!j=14 for !i=14 to 100 step+2 %dest="A"+@str(!j) %source_a="A"+@str(!i) %source_b="N"+@str(!i) tabplace (tab_new, tab_old, %dest,%source_a,%source_b) !j=!j+1 next

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: tabplace

Postby EViews Gareth » Thu Jun 06, 2019 7:58 am

Yes - doing it the way you suggest will work.

Katjes
Posts: 58
Joined: Thu Oct 02, 2008 5:46 am

Re: tabplace

Postby Katjes » Thu Jun 06, 2019 11:58 am

This was my test version - but if I would add a particular row number (not step 2) saved in an additional table (tab_row) the procedure did not work.

Code: Select all

!j=14 for !i=1 to 5 scalar row =@val(tab_row(!i)) !row =row for !i=14 to 100 step+2 %dest="A"+@str(!j) %source_a="A"+@str(!row) %source_b="N"+@str(!row) tabplace (tab_new, tab_old, %dest,%source_a,%source_b) !j=!j+1 next
Do you have any suggestions?

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: tabplace

Postby EViews Gareth » Thu Jun 06, 2019 7:04 pm

Hard to see what you're doing from that.


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 1 guest