Announcement

Collapse
No announcement yet.

Overlay problem

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

  • Overlay problem

    I presently overlay a MACD Curves efs on to a MACD Histogram efs (this is so that both indicators fill the complete height of the window).

    If I drag the The Curves efs on top of the Histo efs I see them both. If I do it the other way round, the Histo efs is not visible. I think this is because the Curves efs uses SetBarBgColor commands which hide the Histo efs?

    The problem is when I try to draw trend lines on the peaks or valleys of the Curves efs. The trend lines (Rays) very often snap to some point too far away from the Curves. I'm guessing the rays are snapping to Histo coordinates, not Curve coordinates, because the Histo efs was the first one there (before the Curves were overlayed)

    I've tried all combinations of displaying the Scale on or off, but that hasn't helped. I've got the magnet set to 1 and tried it both on and off - no difference.

    Any ideas how I can get around this problem? It is most prevalent in short (1 minute) time frame charts.

    Thanks
    shaeffer

  • #2
    Hello shaeffer,

    This issue is not caused by EFS. This has to do with the minimum y-axis increment for the drawing tools, which is 0.01 in eSignal 8.0. You will not be able to anchor trend lines at values in between increments of 0.01 on the y-axis.

    In the eSignal 10.0 version the y-axis decimal precision has been lowered. You shouldn't have a problem with the trend lines in this version.
    Jason K.
    Project Manager
    eSignal - an Interactive Data company

    EFS KnowledgeBase
    JavaScript for EFS Video Series
    EFS Beginner Tutorial Series
    EFS Glossary
    Custom EFS Development Policy

    New User Orientation

    Comment


    • #3
      Hi Jason,
      I have version 10.0 on my other computer, so after the close I opened it and gave it a try..... a definite improvement in trend line anchorability.
      Thanks
      shaeffer

      Comment


      • #4
        My trend line anchor points seem to 'drift'. Where an end point touches a curve now, five minutes later it does not.

        In the case of study 'B' dragged up to overlay study 'A', to which study are trend line points anchored?
        a) to the study that was first in the window, i.e. study 'A', or
        b) the study which has Scale Right selected (assuming the other study has No Scale selected)?

        Both are efs studies, so I hope I'm in the right forum for this Q.
        Thanks
        shaeffer

        Comment


        • #5
          shaeffer

          Where an end point touches a curve now, five minutes later it does not.
          That can happen if the overlaid studies do not share the same scale and the line is drawn relative to the study in the background. This is because the line is actually drawn on the study in the foreground [and uses that study's scale] and as the studies will auto-scale at different rates when the chart scrolls the line will appear to be shifting. In effect the position of the line has not moved relative to the pane on which it was drawn but because the foreground scale has changed the line may no longer be in the same position relative to the background study. You can see this effect even by just scrolling the chart right and left.

          In the case of study 'B' dragged up to overlay study 'A', to which study are trend line points anchored?
          They are anchored to study 'A' which is the foreground study. You can easily verify this by dragging study 'B' onto study 'A' then drawing a line and then unmerging the studies. The line will remain in study 'A' .
          Alex

          Comment


          • #6
            Hi Alex,

            My two studies are the MACD Histogram and the MACD curves. I use separate EFS's precisely so they don't share the same scale because often the all-in-one MACD study histogram bars are too tiny relative to window height. Using separate EFS's allows both the MACD histo bars and curves to fill the window.

            I only ever want to draw trend lines on the MACD curves. If I understood your last reply, these lines would work fine if I dragged the Histo EFS on top of the Curves EFS. The Curves EFS would be then be considered the foreground EFS and trend lines would always anchor to its scale?

            But if I do that (drag the Histo EFS on top of the Curves EFS), the Histo bars are not visible. I think this is because my Curves EFS uses setBarBgColor commands which over-write the Histo bars.... is that the correct reason the Histo bars disappear?

            So my dilemna.....
            Case 1: If Histo EFS on top of Curves EFS, trend lines work well, but histo bars not visible.
            Case 2: If Curves EFS on top of Histo EFS, both studies are visible, but trend lines drawn on the Curves float.

            In case 2, I thought that via Edit Studies, setting the Histo scaling to No-Scale and the Curves scaling to Right-Scale would govern to which study trend lines anchored. But per your reply, it seems that trend line anchoring is based on the foreground study scale, regardless of scaling settings?

            Any thoughts on how I get around this problem?

            You mentioned unmerging. Once studies are overlaid, they can be unmerged?

            Regards
            shaeffer

            Comment


            • #7
              shaeffer
              Based on your description the solution is to have the MACD lines on top and the MACD histogram on the bottom and color the background of the MACD histogram instead of the MACD lines.
              To unmerge the studies right click the chart and select Un-Merge Studies
              Alex

              Comment


              • #8
                Hello Alex.

                I never noticed the Un-Merge Studies command before, thanks.

                It really is the MACD curves I want to color the background of. But as it seems that Bg coloring and anchoring of trend lines to one study, while merged with another study is not possible, so I have un-merged the two studies for now.

                Thanks again,
                shaeffer

                Comment


                • #9
                  shaeffer
                  If you are overlaying the two studies (MACD lines and histogram) then coloring the background of the histogram will produce the same result.
                  If you want you could set the background color of the MACD lines as an option that is enabled through a Funtion Parameter so that you can switch it on or off depending on your requirements (same for the background color of the histogram)
                  Alex

                  Comment


                  • #10
                    Originally posted by Alexis C. Montenegro
                    shaeffer
                    If you are overlaying the two studies (MACD lines and histogram) then coloring the background of the histogram will produce the same result.
                    Alex
                    Hi Alex,
                    Agreed, the background coloring would be the same if the MACD Histogram crossing 0 (= MACD curves crossing) was what I was basing the background coloring on. But it is the change in slope of the MACD fast line that I base my Bg coloring on - it can often produce a signal a bar or two before the lines cross. Often when that line looks flat, the Bg coloring tells me which way it is sloping

                    I suppose I could add the appropriate MACD curve coding to the MACD Histogram EFS (but without displaying the curves) to get Curve based coloring on the Histogram, but that seems like overkill.

                    Interesting idea, to use Function Parameters to turn coloring on or off. Though I want coloring always on for this application, I'll keep that in mind for future use.

                    Thanks
                    shaeffer

                    Comment


                    • #11
                      shaeffer

                      Agreed, the background coloring would be the same if the MACD Histogram crossing 0 (= MACD curves crossing) was what I was basing the background coloring on. But it is the change in slope of the MACD fast line that I base my Bg coloring on ..
                      Just because you are coloring the background of the study that plots the histogram does not mean that the coloring has to be based on the condition of the histogram. It can be based on the condition of the MACD lines regardless of what is being returned to the chart by the script.

                      I suppose I could add the appropriate MACD curve coding to the MACD Histogram EFS (but without displaying the curves) to get Curve based coloring on the Histogram, but that seems like overkill.
                      Not really. You would simply enclose this section of code within the same condition that enables/disables the background coloring which means that instead of evaluating the conditions in one script you will be doing it in the other depending on the requirements of the moment.
                      Alex

                      Comment

                      Working...
                      X