overlay spike graph

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

maxchen
Posts: 191
Joined: Fri Oct 10, 2008 4:03 pm

overlay spike graph

Postby maxchen » Sun Aug 16, 2015 7:47 pm

I am using spike to depict the opposite direction in movement of two price (where x*y<0)

However, spike does not provide an option to align the two series. Thus, I produce 2 graphs, and overlay them

Code: Select all

'2015-08-17 10:20 EV9.20150728 'overlay two graph wfcreate u 8 series x series y x.fill -5, 24, 1, -7, -13, -5, 10, -4 y.fill 35, -4, -3, 2, 4, 3, -7, 24 graph gfx.spike x gfx.addtext(t) "" graph gfy.spike y gfy.addtext(t) "" gfy.setelem(1) lcolor(red) symbol(circle) graph gfd.merge gfx gfy gfd.options size(8,3) gfd.axis range(-20,40) gfd.align(1,0,-3.01) ' gfd.align(1,0,-3.02) ' gfd.align(1,0,-3.015)

the problem is that I can not achieve a perfect overlay. The best choice is align(1,0,-3.01), and it seems no different from align(1,0,-3.02) and align(1,0,-3.015).

Is it possible to find out an exact overlay?
Attachments
Screenshot from 2015-08-17 104501.png
overlay graph
Screenshot from 2015-08-17 104501.png (31.84 KiB) Viewed 2401 times

Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 2 guests