Announcement

Collapse
No announcement yet.

stochastic crossover

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • stochastic crossover

    I am a new user. Does anyone have the formula for an alert based on %k crossing over %d? (ie %k crosses above %D signals a buy alert and %k crosses below %d signals a sell alert).

    Thanks

  • #2
    bear777
    The attached efs should do what you asked.
    All parameters for the indicator can be modified using Edit Studies.
    Alex

    Attached Files

    Comment


    • #3
      thanks Alexis, that is what I was looking for.

      Could you help me find or write a formula that creates a moving stop loss using stochastic crossovers.
      For example, after a buy signal (ie%k crosses %D), a stop is placed under the price low created by the stochastic crossover.
      THen each time %k crosses above %d the stop will be moved up to the price low created by the stochastic crossover.

      the opposite for sell signals.

      An example using the chart you sent me, a buy signal is triggered on March 10 and a stop is placed at that low.

      Then the stop would be moved up to the low formed on the march 31st buy cross, then again on the April 5th cross, then the stop is triggered on the the next down move at around 8200.

      bear

      Comment


      • #4
        no alert?

        Hi there,
        I download the basicstochastic(alerts).efs and set it on chart, but there is no alert pop up, do i need to setup something for the alert?

        also i add a line to play a sound when the alert is triggered, neither it work? help!
        thanks

        Comment


        • #5
          andyg
          You may want to check if you have the Popup on Alert enabled. Select Tools->EFS->Alert List. This should open the Triggered Alert List window. Right click on it and make sure there is a check in Popup on Alert.
          As to adding a line to play sound it depends on how you did it.
          If for example you added it in the following way

          if(vStoch.getValue(StochStudy.FAST,-1) < vStoch.getValue(StochStudy.SLOW,-1)&&
          vStoch.getValue(StochStudy.FAST) > vStoch.getValue(StochStudy.SLOW))
          Alert.addToList(getSymbol(),"BUY (Crossing Up)",Color.black,Color.blue);
          Alert.playSound("ding");

          it will not work. You need to write it in the following way (note the {} brackets that have been added)

          if(vStoch.getValue(StochStudy.FAST,-1) < vStoch.getValue(StochStudy.SLOW,-1)&&
          vStoch.getValue(StochStudy.FAST) > vStoch.getValue(StochStudy.SLOW)) {
          Alert.addToList(getSymbol(),"BUY (Crossing Up)",Color.black,Color.blue);
          Alert.playSound("ding");
          }

          You will need to repeat this also with the other condition.
          Hope this helps
          Alex

          Comment


          • #6
            Thank you Alex, but I did the code as you said and check the alert it's checked, still nothing happened, what's wrong with me?

            The 'Triggered Alert List' is empty.

            days ago, i download the DiNopli Pre Stoch with sound and it did not work either. Let's see what i did wrong.
            - download the efs file from your link
            - save it in the MyLib folder in Formulas folder under eSignal
            - right click a chart -> Formulas -> MyLib -> xxx.efs
            wait for alert or sound play but nothing happened, the chart is set to 1 minutes time frame to allow more signals.

            Comment


            • #7
              andyg
              The procedure you outlined is correct so I am unsure as to why the efs is not providing any alerts at your end. FWIW I have been running the script both in real time and in Tick Replay and found that it actually provides too many alerts because it triggers on every tick during crossovers.
              Here is the same efs modified to trigger the alerts only at the close of the bar while still plotting in real time.
              Alex
              Attached Files
              Last edited by ACM; 10-11-2003, 03:45 AM.

              Comment

              Working...
              X