Jump to content

Welcome to the new Traders Laboratory! Please bear with us as we finish the migration over the next few days. If you find any issues, want to leave feedback, get in touch with us, or offer suggestions please post to the Support forum here.

shortski

Members
  • Content Count

    15
  • Joined

  • Last visited

Personal Information

  • First Name
    TradersLaboratory.com
  • Last Name
    User
  • Country
    Canada

Trading Information

  • Vendor
    No
  1. I tried using the NoPlot a number of times with the same result; vars: value1(0), value2(0); value1 = $rtOscillatorDivergence(high,low,GordoMACDDiff(close,12,26),1.0); value2 = ThreeLineBreak; If value1 > 0 and value2 > 0 then begin Plot1(1,"Buy",green); end else If value1 < 0 and value2 < 0 then begin Plot1(-1,"Sell",red); end else NoPlot(1); if(Value1 > 0 and value2 > 0) then Green else if(Value1 < 0 and value2 < 0) then Red I just tried using sneo's suggestion for a ChartBGColor and it basically plots the same as my original code but still won't stop plotting; Vars: Combo(0), ComboColor(ChartBGColor); Inputs: ChartBGColor(black); value1=GordoMACDDiff(Close,12,26); value2=$rtOscillatorDivergence(high,low,value1,0.9); value3 = ThreeLineBreak; Condition1 = value2 >=0 and value3 >=0; Condition2 = value2 <=0 and value3 <=0; if Condition1 then begin Combo=1; ComboColor= Blue; end else if Condition2 then begin Combo=-1; ComboColor= Red; end else begin Combo=0; ComboColor= ChartBGColor; end; Plot1( Combo, "Combo", ComboColor); So now, I will try and modify this code with "else NoPlot" Thank you all for your suggestions here. Shorski
  2. Well, that is the inherent problem. I posted the eld's of the GordoMACDDiff above and the only thing missing that I have is the way I input the GordoMACDDiff into the OscillatorDivergence. And that is; Name Value SeriesHigh High SeriesLow Low Osc GordoMAVDDiff(Close,12,26) pctDivergence 0.9 PlotLvel 0 Other than that, the code for the ThreeLineBreak and the OscillatorDivergence are proprietary and I lease them from EOT. This did work before, but I reformatted my HD and for some reason, this is the only code I didn't save. So, I believe all the inputs are ok and it is something small in the way I am coding them. If you can see the problem, that would be great. Thanks Shortski
  3. Here is a shot of the chart with only the two indicators on it. Price action then ThreeLineBreak then OscillatorDivergence. Thanks for your patience and help in this matter. I still have to try the other suggestion above about changing the colors to Black.
  4. I cannot post the ThreelineBreak Function as it is a leased indicator. On the chart, it is the continuous indicator plotting in sub graph 2. The other indicator in sub graph 2 is the Oscillator Divergence. The OscillatorDivergence is also a leaded indicator that I have inserted a MACD offset into. The Function for the MACDDiff is; Inputs: FastLength(NumericSimple), SlowLength(NumericSimple), MACDLength(NumericSimple); Vars: double var0(0), double var1(0); var0 = MACD( Close, FastLength, SlowLength ) ; var1 = XAverage( var0, MACDLength ) ; gordoMACDDiff = (var0 - var1) ; And the Indicator is; inputs: FastLength( 12 ), SlowLength( 26 ), MACDLength( 9 ), EMALength(9) ; variables: var0( 0 ), var1( 0 ), var2( 0 ), EMAMACDDIFF(0) ; var0 = MACD( Close, FastLength, SlowLength ) ; var1 = XAverage( var0, MACDLength ) ; var2 = (var0 - var1) ; EMAMACDDIFF = Xaverage(var2, EMALength); Plot3( var2, "MACDDiff" ) ; Plot4( 0, "ZeroLine" ) ; Plot5(EMAMACDDIFF, "EMADiff"); condition1 = var2 crosses over 0 ; if condition1 then Alert( "Bullish alert" ) else begin condition1 = var2 crosses under 0 ; if condition1 then Alert( "Bearish alert" ) ; end; I do know that the Oscillator gives a return of 0.00 and it is either a red or green 0.00. The ThreeLineBreak returns either a +1 or a -1. I understand what you are saying about the >= and <= 0 but it is the only way to get it to plot at all. Any changes creates a blank plot. I have tried a +/-1 as well as +/-1 for the ThreeLineBreak and 'red' and 'green' for the OscillatorDivergence.
  5. This is the code and the attachment shows you what it comes out like in the lower subgraph. I circled the areas where it should plot but I am trying to remove it from the other areas and just have it blank. Someone suggested to me to put a Switch in the code so the code only plots when the condition is present. I haven't tried this yet as I ahve never tried that. value1=GordoMACDDiff(Close,12,26); value2=$rtOscillatorDivergence(high,low,value1,0.9); value3 = ThreeLineBreak; Condition1 = value2 >=0 and value3 >=0; Condition2 = value2 <=0 and value3 <=0; If Condition1 then begin Plot1(1,"Buy",green); end; If Condition2 then begin Plot1(-1,"Sell",red); end;
  6. That was a good Idea but when I entered it, the chart stayed the same. That is it plots a histogram bar on every price bar. I also tried; if not condition1 and not condition2 then noplot(1); and got the same result. Thanks though. S
  7. I tried Else NoPlot and Else NoPlot(1) and when I try to complile it, it wants 'end' where the 'else' is. Right now, I am trying to vary the code to see if I can come up with returns other than +/1 1. Thanks for all the help on this guys. I appreciate the inputs. S
  8. Interesting. It removed the conditions where the set up was present as well as the green bars. So, basically, I need almost the exact opposite of that. I will play with it a bit after the market closes.
  9. Yes, both indicators plot 1s and 0s. So is there any way to get the new indicator to plot when both conditions are met (only)?
  10. Yes, that is what they return. So there is no way for the new Plot to only show when both parameters are present then?
  11. It is partially EOT and partially mine but the problem is not in the Indicators, it is a problem with the code syntax. That is why I am trying to figure it out without bothering them.
  12. Ok, thanks for that. I will have a look later and post the chart when it is working again.
  13. I click on the paperclip and nothing happens. I click on the "Manage Attachments" below and nothing happens. So maybe I just cannot find the right icon to attach a file?
  14. Hi all. I am relatively new to EasyLanguage and am trying to combine 2 indicators to show me a 3rd indicator when 2 conditions match up in the first 2. I have it so that it will Plot when these 2 conditions are right but I cannot get it to stop plotting. I have it set to a histogram. I tried "Else NoPlot" but that just made everything go blank. This is the Code I have; value1=GordoMACDDiff(Close,12,26); value2=$rtOscillatorDivergence(high,low,value1,0.9); value3 = ThreeLineBreak; Condition1 = value2 >=0 and value3 >=0; Condition2 = value2 <=0 and value3 <=0; If Condition1 then begin Plot1(1,"Buy",green); end; If Condition2 then begin Plot1(-1,"Sell",red); end; I wanted to add a screenshot but when I click on the attachment icon, nothing happens? Thanks Shortski
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.