Announcement

Collapse
No announcement yet.

histogram that show the diff. between 2 symbols, please help

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • histogram that show the diff. between 2 symbols, please help

    Hi all,
    I'm a new user with very little code ability, and I need to build an indicator.

    When I put 2 symbols on a chart, on the same axys, I would like to put an indicator, an histogram, that show the difference between the 2 symbols(indexes or anything else), with a 0 line. When the first symbol cross over the second, the indicator goes over the 0 line, when the first symbol cross under the second, the indicator goes under the 0 line.
    Ideally I need it like an histogram. (maybe there is already one existing?)
    I need to build it asap, so any help is welcome.

    Thank you very much

    Tony
    Last edited by tony11; 06-13-2006, 05:27 AM.

  • #2
    2 Symbol Difference Histogram

    I am interested in this as well. I tried modifying the customMACD to incorporate 2 symbols, but that did not display differences.

    I would have thought that there would be at least an EFS to show differentials in correlated pairs trading that could be used, but searches for that aren't yielding results either.

    Can someone pint the way to an indicator that shows the difference between two symbols in any graphic format?

    Comment


    • #3
      Re: 2 Symbol Difference Histogram

      Look in the specialty scripts folder. There is an efs there for Pearson correlation coefficients. In it, you will find a straight forward way to put two symbols on one chart and get the price of each. You can add a line to calculate the difference between these two price values. Then, just change the last line and "return" the difference variable you just calculated to the chart. Hope this helps.

      Originally posted by MKen

      I would have thought that there would be at least an EFS to show differentials in correlated pairs trading that could be used, but searches for that aren't yielding results either.

      Can someone pint the way to an indicator that shows the difference between two symbols in any graphic format? [/B]

      Comment

      Working...
      X