Hi all.
I wrote a subroutine that shade a graph according to a series. The program is as below.
My problem is, after shading, the graph was given a verticle black line(either at the very beginning or the end of a graph)when the graph begins or ends with a shade area.
Could anyone tell me where this line is from and how to solve it? Thank you very much in advance.
subroutine shade(series x, graph %graphname)
smpl @all
scalar obs=@obs(x)
scalar nas=@nas(x)
scalar total=obs + nas
for !i=2 to total
if x(!i)>x(!i-1) then
%shadedate=@otods(!i-1)
%shadedate2=@otods(!i)
graphname.draw(shade, bottom, rgb(215, 216, 203)) %shadedate %shadedate2
endif
next
endsub
a question about shading program.
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
a question about shading program.
- Attachments
-
- graph.pdf
- (8.98 KiB) Downloaded 280 times
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: a question about shading program.
Maybe it is the time of the morning, but I can't quite see what form X should take. How do you specify X to create the shading?
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: a question about shading program.
Actually, I may have figured it out, but I cannot replicate the issue you're seeing. What's the build date of your copy of EViews (available from Help->About EViews)?
Re: a question about shading program.
It says feb 2 2011 .
so I guess the version should be fine.
the version is 7.1.
Also to answer your question about x, it could be any series of any frequency.
so I guess the version should be fine.
the version is 7.1.
Also to answer your question about x, it could be any series of any frequency.
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13604
- Joined: Tue Sep 16, 2008 5:38 pm
Re: a question about shading program.
You might want to update your copy to the latest version.
If you still have the problem, could you upload the workfile and the program that calls the subroutine?
If you still have the problem, could you upload the workfile and the program that calls the subroutine?
Who is online
Users browsing this forum: No registered users and 2 guests
