Page 48 of 54 FirstFirst ... 38 46 47 48 49 50 ... LastLast
Results 471 to 480 of 540
Like Tree74Likes

Requests and Raw Ideas

This is a discussion on Requests and Raw Ideas within the General Discussion forums, part of the Trading Forum category; hi all coding experts can you tell me exact logic of below code . please help. Code: #property indicator_chart_window #property ...

      
   
  1. #471
    Junior Member
    Join Date
    May 2013
    Posts
    10

    coding help

    hi all coding experts can you tell me exact logic of below code . please help.


    Code:
    #property indicator_chart_window
    #property indicator_buffers 2
    #property indicator_width1 2
    #property indicator_color1 Lime
    #property indicator_width2 2
    #property indicator_color2 Red
    extern int qual=5;
    extern int len=5;
    extern int Distance = 1;
    extern int Countbars=1000;
    double Up[];
    double Dn[];
    double point;
    double bs=0;
    double index=0;
    double bindex=0;
    double sindex=0;
    double length=0;
    double ret=0;
    int init() {
    if(Digits==3 || Digits==5) {
    point=10*Point;
    }
    else{ 
    point=Point;
    }
    IndicatorBuffers(2);
    SetIndexStyle(0, DRAW_ARROW);
    SetIndexBuffer(0, Up);
    SetIndexArrow(0,161);
    SetIndexStyle(1, DRAW_ARROW);
    SetIndexBuffer(1, Dn);
    SetIndexArrow(1,161);
    
    return (0);
    }
    int deinit() {
    return (0);
    }
    int start() {
    bool TurnedUp = false;
    bool TurnedDown = false;
    double highest,lowest;
    int i,limit,limit2;
    int counted_bars = IndicatorCounted();
    if(counted_bars < 0) 
    return(-1);
    
    limit=Countbars-counted_bars;
    if (i> limit2) 
    limit2= i; 
    if (limit2 <Countbars-1)
    limit =Countbars- 1; 
    
    for( i=limit; i>=0; i--) {
    if (Close[i]>Close[i+4]){ 
    bindex=bindex+1;
    }
    if(Close[i]<Close[i+4]){ 
    sindex=sindex+1;
    }
    ret=0;
    index=0;
    
    if ((bindex>qual) && (Close[i]<Open[i])&& (High[i]>=High[iHighest(Symbol(),0,MODE_HIGH,len,i+1)])) { 
    index=1;
    bindex=0;
    ret=-1;
    }
    if ((sindex>qual) && (Close[i]>Open[i])&& (Low[i]<= Low[iLowest(Symbol(),0,MODE_LOW,len,i+1)])) {
    index=-1;
    sindex=0;
    ret=1;
    }
    if (ret==1 && i!=0){
    Up[i]=Low[i]-Distance*point;
    }
    if (ret==-1 && i!=0){ 
    Dn[i]=High[i]+Distance*point;
    }
    }
    
    if (i> limit2) 
    limit2= i;
    
    return (0);
    }

  2. #472
    igorad
    Guest
    Quote Originally Posted by debashis View Post
    hi all coding experts can you tell me exact logic of below code . please help.


    Code:
    #property indicator_chart_window
    #property indicator_buffers 2
    #property indicator_width1 2
    #property indicator_color1 Lime
    #property indicator_width2 2
    #property indicator_color2 Red
    extern int qual=5;
    extern int len=5;
    extern int Distance = 1;
    extern int Countbars=1000;
    double Up[];
    double Dn[];
    double point;
    double bs=0;
    double index=0;
    double bindex=0;
    double sindex=0;
    double length=0;
    double ret=0;
    int init() {
    if(Digits==3 || Digits==5) {
    point=10*Point;
    }
    else{ 
    point=Point;
    }
    IndicatorBuffers(2);
    SetIndexStyle(0, DRAW_ARROW);
    SetIndexBuffer(0, Up);
    SetIndexArrow(0,161);
    SetIndexStyle(1, DRAW_ARROW);
    SetIndexBuffer(1, Dn);
    SetIndexArrow(1,161);
    
    return (0);
    }
    int deinit() {
    return (0);
    }
    int start() {
    bool TurnedUp = false;
    bool TurnedDown = false;
    double highest,lowest;
    int i,limit,limit2;
    int counted_bars = IndicatorCounted();
    if(counted_bars < 0) 
    return(-1);
    
    limit=Countbars-counted_bars;
    if (i> limit2) 
    limit2= i; 
    if (limit2 <Countbars-1)
    limit =Countbars- 1; 
    
    for( i=limit; i>=0; i--) {
    if (Close[i]>Close[i+4]){ 
    bindex=bindex+1;
    }
    if(Close[i]<Close[i+4]){ 
    sindex=sindex+1;
    }
    ret=0;
    index=0;
    
    if ((bindex>qual) && (Close[i]<Open[i])&& (High[i]>=High[iHighest(Symbol(),0,MODE_HIGH,len,i+1)])) { 
    index=1;
    bindex=0;
    ret=-1;
    }
    if ((sindex>qual) && (Close[i]>Open[i])&& (Low[i]<= Low[iLowest(Symbol(),0,MODE_LOW,len,i+1)])) {
    index=-1;
    sindex=0;
    ret=1;
    }
    if (ret==1 && i!=0){
    Up[i]=Low[i]-Distance*point;
    }
    if (ret==-1 && i!=0){ 
    Dn[i]=High[i]+Distance*point;
    }
    }
    
    if (i> limit2) 
    limit2= i;
    
    return (0);
    }
    Hi debashis,

    This indicator shows Buy/Sell signals as bounces from the Upper/Lower Donchian Bands with the period by default per=5.

    To get a buy signal the following condition should be met:

    Close > Open and Low <= Lower Donchian Band and bear candle counter > qual parameter,

    where the bear candle counter counts candles for Close < Close[4] from the last buy signal.

    To get a sell signal:

    Close < Open and High >= Upper Donchian Band and bull candle counter > qual parameter,

    where the bull candle counter counts candles for Close > Close[4] from the last sell signal.

    Regards,
    Igor
    debashis likes this.

  3. #473
    Junior Member
    Join Date
    May 2013
    Posts
    10
    Quote Originally Posted by igorad View Post
    Hi debashis,

    This indicator shows Buy/Sell signals as bounces from the Upper/Lower Donchian Bands with the period by default per=5.

    To get a buy signal the following condition should be met:

    Close > Open and Low <= Lower Donchian Band and bear candle counter > qual parameter,

    where the bear candle counter counts candles for Close < Close[4] from the last buy signal.

    To get a sell signal:

    Close < Open and High >= Upper Donchian Band and bull candle counter > qual parameter,

    where the bull candle counter counts candles for Close > Close[4] from the last sell signal.

    Regards,
    Igor
    WOW! thanks coding master

  4. #474
    Member
    Join Date
    Dec 2018
    Posts
    32

    Volume MACD and Linear Regression Volume Overlay

    Hey there, couldn't find those indicators for MT4. Does anyone have them to share??

    The price based indicators are useless. This MACD based on volume is so much better. I believe it is a matter of just tweaking the regular MACD to use volume info as input, instead of price, and then make it show on top of volume bars.

    The linear regression based and overlaid on volume is better than a MA, it shows a nice slope.
    Attached Thumbnails Attached Thumbnails Requests and Raw Ideas-volumemacd2.png   Requests and Raw Ideas-volumemacd.png   Requests and Raw Ideas-linearregression.png  

  5. #475
    igorad
    Guest
    Hi logicgate,

    Please check out the updated AllMACD indicator which is able to use Volumes for Fast and Slow MAs.

    Regards,
    Igor
    mosiskv and logicgate like this.

  6. #476
    Member
    Join Date
    Dec 2018
    Posts
    32
    Quote Originally Posted by igorad View Post
    Hi logicgate,

    Please check out the updated AllMACD indicator which is able to use Volumes for Fast and Slow MAs.

    Regards,
    Igor
    Wow that is awesome!! Thanks a lot brother.

  7. #477
    Member
    Join Date
    Dec 2018
    Posts
    32
    Hi there! I have an idea for an indicator.

    It will plot a light green dot under a bar meeting this criteria:

    It traded below it's open, reversed and closed above it's open.

    A 20 period VWMA is above a 20 period SMA. (you can change those values in indicator options to adjust sensitivity)

    Voume is average or above average (you can change the volume MA period in indicator settings, nice to have SMA and EMA)

    CVI (cumulative volume index) is above it's 50 day moving average. (you can change this value in the indicator options to adjust sensitivity).

    MFI (money flow index) is above it's 50 day moving average. (you can change this value in the indicator options to adjust sensitivity)

    *** You have to choose between CVI or MFI method in indicator options, can't have both at same time***

    If the bar is an UP bar (it closed above previous bar close), then a bigger DARK green dot appears. (you can choose how many bars to look back, 1, 2, etc.. in the case you want it to close above more bars to trigger).

    For the bearish signal a light red dot appears on top of bar, same settings as above, but inverted (except for volume)

    The sign can be arrows, dots, does not matter...

    Thanks!! God Bless and good trades!

  8. #478
    Member
    Join Date
    Dec 2018
    Posts
    32
    Another idea from the same book from where I posted the volume MACD pics.

    It is an Up/Down Volume Oscillator. It is the same thing as the cumulative delta indicator for MT4, but cumulative delta keeps adding the results of it's calculation to a running series of data. The Up/Down oscillator does not, it is like a "live" version.
    Attached Thumbnails Attached Thumbnails Requests and Raw Ideas-thumbnail_image3.png   Requests and Raw Ideas-thumbnail_image2.png   Requests and Raw Ideas-thumbnail_image1-1-.png   Requests and Raw Ideas-thumbnail_image1.png  

  9. #479
    Member
    Join Date
    Aug 2017
    Posts
    75
    Dear ND and Igorad ,

    Is there any REAL TIME equity line indicator showing any drawdown between opening and closing a trade?

  10. #480
    Senior Member Taylor Woods's Avatar
    Join Date
    Jan 2019
    Posts
    299
    Before a trader can make investment in various trades or he can start trading in this world market place, he must try to conduct proper trading analysis. A wide variety of technical indicators like pivot points, MACD, forex indicator or signals, etc. are now being used by the forex traders. And yes, without any doubt a trader will require proper trading knowledge to find out the results of the trading decisions.

Page 48 of 54 FirstFirst ... 38 46 47 48 49 50 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •