| Coding Forum Collaborate, receive help, or discuss coding related issues. |
![]() | | Tweet | |
| | #1 | ||
![]() | I would like a showme study to plot above and below the bar that crosses a moving average. Only on the first close above or below on each occurance. For up the upperline and for down the lower line. _________________________ ________ Inputs: Length(100), TrigAvg(20), UpColor(Green), DnColor(Magenta); Variables: back(0), xAvg(0); PLOT1 (TimeSeriesForecast (Length, 0), "Trigger") ; xAvg = XAverage (PLOT1, TrigAvg) ; PLOT2 (xAvg, "AverageTSF") ; IF (PLOT2 >= PLOT1) THEN BEGIN SETPLOTCOLOR (1, DnColor) ; SETPLOTCOLOR (2, DnColor) ; END ELSE BEGIN SETPLOTCOLOR (1, UpColor) ; SETPLOTCOLOR (2, UpColor) ; END ; | ||
| |
|
| | #2 | ||
![]() | Re: Show Me Help Example code: Code: Input: Length(100); Input: TrigAvg(20); Input: UpColor(Green); Input: DnColor(Magenta); Var: back(0); Var: xAvg(0); Var: xTime(0); xAvg = XAverage (xTime, TrigAvg) ; xTime = TimeSeriesForecast (Length, 0); If close crosses above xAvg then PlotPaintBar( High, Low, Open, Close, "Cross", UpColor , 0, 2 ) ; If close crosses below xAvg then PlotPaintBar( High, Low, Open, Close, "Cross", DnColor , 0, 2 ) ; | ||
| |
|
| | #3 | ||
![]() | Re: Show Me Help Thanks | ||
| |
|
![]() |
| Thread Tools | |
| Display Modes | Help Others By Rating This Thread |
| |
| ∧ Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Futures I Trade Show & Brooks Book | brownsfan019 | The Candlestick Corner | 638 | 04-25-2012 11:00 AM |
| Help with Simple Show Me | 9146894me | Coding Forum | 14 | 06-03-2010 09:36 AM |
| OEC Show Case | Chouca | Open E Cry | 4 | 05-06-2010 09:15 PM |
| Converting a "Show Me" for Scanning | daedalus | Coding Forum | 15 | 04-14-2010 10:03 PM |
| Show us your roots! | Nick1984 | General Discussion | 13 | 06-18-2007 11:41 PM |