A Simple Moving Average Cross Strategy (& how to use valuewhen)

Поділитися
Вставка
  • Опубліковано 23 лис 2024

КОМЕНТАРІ • 31

  • @TheArtOfTrading
    @TheArtOfTrading  Рік тому +1

    🚩 Source Code: courses.theartoftrading.com/pages/simple-moving-average-cross-strategy
    🚩 My Socials & Free Weekly Newsletter: theartoftrading.com
    🚩 FREE Pine Script Basics Course: courses.theartoftrading.com/courses/pine-script-basics-course
    🚩 Pine Script Mastery Course: courses.theartoftrading.com/courses/pine-script-mastery

  • @damonsams
    @damonsams Рік тому +4

    Thanks Matt, as always a great lesson. Appreciate your style of teaching!

  • @mariocollado5072
    @mariocollado5072 Рік тому

    Great video and code developing. Many thanks.

  • @barissari3378
    @barissari3378 Рік тому +1

    Hi Matt, why did you use the "for" loop instead of ta.highest or ta.lowest function? Any particular reason? Thanks for the lesson, always following your courses.

  • @willowkonrad8893
    @willowkonrad8893 Рік тому

    A cool one I am thinking of as well as having a trailing stop loss, have a take profit, that stays a certain distance ahead of the smaller of the smaller moving average value, that can be triggered by freakishly large bars or a couple, then wait for a retracement back to the smaller average ,and buys back in. Thanks for your efforts.

  • @MrDoekoe
    @MrDoekoe Рік тому

    Really enjoy your posts! Thanks so much and greetings from the Netherlands 🙌

  • @PerformancePlusTuning
    @PerformancePlusTuning Рік тому

    Another great lesson, TY!

  • @lukeiaboni
    @lukeiaboni Рік тому

    Thanks Matt!👏

  • @karliqarsifroberts4804
    @karliqarsifroberts4804 Рік тому

    Thank you for your video.

  • @lapogk1543
    @lapogk1543 Рік тому

    Great Teaching. I am learning through your videos after my retirement from Non-IT background. Thanks a lot for your efforts. How can I add the location concept in the code. ( distance between the MA and the cross over price) and exit if the subsequent candle closes below the low of the cross candle in the case of buy and high of the cross candle in the case of short entry. Just give me an idea and I will try myself to code. Thanks again

  • @patriciogalvan7595
    @patriciogalvan7595 Рік тому

    Matt, I have 2 comments, I have had problem of repainting with de ta. cross in the past, so I dont use It. The second is, why didn t you use highest(high)?

  • @milkotsanzov
    @milkotsanzov Рік тому

    Is there a way to check and enter a trade only if there is no wick to the candle of the cross and the following 10 candles if the condition is not met on the cross? For example when there is a buy cross only enter when there is no lower wick of the candle at the moment of the cross and if there is then check the next 10 candles for this to be valid and then enter the buy?

  • @lapogk1543
    @lapogk1543 Рік тому

    one more doubt. For example, i created two moving averages with selection criteria for time frame for each. How can i create a strategy for the crossover of MA in different time frames. Thanks

  • @georgebrill3072
    @georgebrill3072 Рік тому

    Enjoyed your video. Can Pinescripts be used to create custom scans?

  • @ezrakoper
    @ezrakoper Рік тому

    Excellent, as always

  • @free-4-1
    @free-4-1 Рік тому

    Thank you. It helps a lot.

  • @ichimokatrader1198
    @ichimokatrader1198 Рік тому

    I really want to just highlight the candle and not have the line through the whole column. How can we just highlight the candle itself?

  • @jonasherman9195
    @jonasherman9195 Рік тому

    Hi, I would like to ask how I can code to know which is the lowest moving average. More specifically I would like to visualize each candle that hits the lowest moving average. Then, I would like to code that if in the last 20 candles the lowest moving average was hit and broke the rest of the moving averages to the upside, there is an entry on the next time it hit the 21 moving average. This is to give some context but I am just asking how to code to mark the touches with the lowest moving average. Thanks a lot in advance!

  • @Godfidence09
    @Godfidence09 Рік тому

    Marvelous Matt !!!

  • @therealdonovanjones3066
    @therealdonovanjones3066 Рік тому

    Can this conditional exit be transmitted to PineConnector? Just wondering if an auto-trader could be implemented with this exit strategy. And could you potentially create an input for the number of bars back to be adjusted? like i = 1 to (bar_length)??

  • @dylanlangmead7610
    @dylanlangmead7610 Рік тому

    can i ask, where did you learn to code pinescript?

  • @jcpamart83
    @jcpamart83 Рік тому

    Hi, I try to use your script with MA5 and MA13. But it makes a lot of sells between 2 buys. How can we modify this script to have only 1 buy and 1 sell at each action ? Thanks for your help

  • @snikmotrenbue
    @snikmotrenbue Рік тому

    Thank you for this lesson. As usual, you are an excellent instructor and programmer. If I had your Pine Script knowledge, I would test strategies of the ICT type or the DR/iDR type with the FVG and OB indicators. Indicators are candy, while price action concepts are chess. Today I pasted your script in my TV chart and believe it will help me. Thanks again. Keep up the great work. Tom

  • @aliabolhassanpour4418
    @aliabolhassanpour4418 Рік тому

    Thank you so much for preparing such invaluable videos. I would be greatly appreciate if you guide us in developing pine script to determine divergence based on MACD or RSI indicators.

  • @willowkonrad8893
    @willowkonrad8893 Рік тому

    awesome

  • @Berghiker
    @Berghiker Рік тому +2

    A strategy without the ATR means nothing to me.

    • @kingmonk44
      @kingmonk44 Рік тому

      😂

    • @amanchaure5584
      @amanchaure5584 Рік тому +1

      True af!!!
      ATR is the real game changer.

    • @Berghiker
      @Berghiker Рік тому +2

      @@amanchaure5584 Yes, it is!!

    • @kingmonk44
      @kingmonk44 Рік тому

      @@amanchaure5584 and you use it to put the stop 1 ATR below "a level"? or do you use it for something else?

    • @louiss2595
      @louiss2595 Рік тому

      How are you guys using it?