Programming a table

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Jason, EViews Moderator, EViews Matt

miorinnovo
Posts: 123
Joined: Sun Mar 01, 2015 5:01 pm

Re: Programming a table

Postby miorinnovo » Thu Feb 01, 2018 2:50 pm

Gareth, you, Sir, are the man.

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

Re: Programming a table

Postby EViews Gareth » Thu Feb 01, 2018 3:14 pm

Beer donations can be sent to support@eviews.com :D
Follow us on Twitter @IHSEViews

miorinnovo
Posts: 123
Joined: Sun Mar 01, 2015 5:01 pm

Re: Programming a table

Postby miorinnovo » Fri Feb 02, 2018 2:20 pm

Here's another table question.

I was hoping to have the first column in my table be the names in my for string. But if I put {%string} in brackets to tell the table to read it It just displays {%string}. Is there a workaround for this?

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

Re: Programming a table

Postby EViews Gareth » Fri Feb 02, 2018 2:40 pm

Don't follow.
Follow us on Twitter @IHSEViews

miorinnovo
Posts: 123
Joined: Sun Mar 01, 2015 5:01 pm

Re: Programming a table

Postby miorinnovo » Fri Feb 02, 2018 3:05 pm

Here's the code

Code: Select all

for %names a b c d e f
   !row = !row + 1
   {%table}(!row,1) = "{%names}"
   {%table}(!row,2) = @mean({%names}{%somethingelse})


So I was hoping to get the first column to be rows that say "a" then next row says "b" etc. But they all just actually say {%names}.

also I want the second column to give me the mean of a{%somethingelse}

Thanks

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

Re: Programming a table

Postby EViews Gareth » Fri Feb 02, 2018 3:16 pm

Code: Select all

{%table}(!row,1) = %names
Follow us on Twitter @IHSEViews

miorinnovo
Posts: 123
Joined: Sun Mar 01, 2015 5:01 pm

Re: Programming a table

Postby miorinnovo » Fri Feb 02, 2018 3:22 pm

ok, that one hurt.
thanks


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 9 guests