Announcement

Collapse
No announcement yet.

Woodie Pivots

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

  • Woodie Pivots

    File Name: Woodie_Pivots.efs

    Description:
    Contains Pivot Points based on theories by Woodie.

    Formula Parameters:


    Notes:


    Download File:
    Woodie_Pivots.efs

    Image:



    EFS Code:
    PHP Code:
    /************************
    Copyright © eSignal, 2003
    *************************/

    /*
    Description:    Contains Pivot Points based on theories by Woodie.
                    
                    PP = (YesterdaysHigh + YesterdaysLow + (TodaysOpen x 2)) / 4
                    R1 = (PP x 2) - YesterdaysLow
                    S1 = (PP x 2) - YesterdaysHigh
                    R2 = PP + R1 - S1
                    S2 = PP - R1 + S1
                    R3 = PP + R2 - S2
                    S3 = PP - R2 + S2

    */


    function preMain() {
        
    setPriceStudy(true);
        
    setStudyTitle("Woodie Pivots");
        
    setCursorLabelName("PP-R3"0);
        
    setCursorLabelName("PP-R2"1);
        
    setCursorLabelName("PP-R1"2);
        
    setCursorLabelName("PP"3);
        
    setCursorLabelName("PP-S1"4);
        
    setCursorLabelName("PP-S2"5);
        
    setCursorLabelName("PP-S3"6);

        
        
    // R3
        
    setDefaultBarStyle(PS_SOLID0);
        
    setDefaultBarFgColor(Color.RGB(255,0,255), 0);
        
    setDefaultBarThickness(30);
        
        
    // R2
        
    setDefaultBarStyle(PS_DASH1);
        
    setDefaultBarFgColor(Color.RGB(255,0,0), 1);
        
    setDefaultBarThickness(21);

        
    // R1
        
    setDefaultBarStyle(PS_DOT2);
        
    setDefaultBarFgColor(Color.RGB(0,0,255), 2);
        
    setDefaultBarThickness(12);   

        
    // Woodie Pivot Point
        
    setDefaultBarStyle(PS_SOLID3);
        
    setDefaultBarFgColor(Color.RGB(0,0,0), 3);
        
    setDefaultBarThickness(13);

        
    // S1
        
    setDefaultBarStyle(PS_DOT4);
        
    setDefaultBarFgColor(Color.RGB(0,0,255), 4);
        
    setDefaultBarThickness(14);

        
    // S2
        
    setDefaultBarStyle(PS_DASH5);
        
    setDefaultBarFgColor(Color.RGB(255,0,0), 5);
        
    setDefaultBarThickness(25);
        
        
    // S3
        
    setDefaultBarStyle(PS_SOLID6);
        
    setDefaultBarFgColor(Color.RGB(255,0,255), 6);
        
    setDefaultBarThickness(26);
    }

    // Start of Performance addition
    var vLastRawTime null;
    var 
    vLastPP null;
    var 
    vLastPPR1 null;
    var 
    vLastPPR2 null;
    var 
    vLastPPS1 null;
    var 
    vLastPPS2 null;
    var 
    vLastArray null;
    var 
    vSymbol null;
    var 
    vInterval null;
    var 
    vReset true;


    function 
    main() {
        var 
    vH;
        var 
    vL;
        var 
    vC;
        var 
    vRawTime;
        var 
    vBarTime;
        var 
    vIndex;

        var 
    nState getBarState();
        if(
    vReset == true) {
            
    vLastRawTime null;
            
    vLastArray null;
            
    vLastPP null;
            
    vLastPPR1 null;
            
    vLastPPR2 null;
            
    vLastPPS1 null;
            
    vLastPPS2 null;
            
    vInterval getInterval();
            
    vSymbol getSymbol();
            
    vSymbol += ",D";
            
    vReset false;
        }

        
    vRawTime getDay();
        if(
    vRawTime == null)
            return;

        
    // Start of Performance addition
        
    if(vRawTime != null && vLastRawTime != null) {
            if(
    vRawTime == vLastRawTime) {
                return 
    vLastArray;
            }
        }
        
        if(
    vInterval == null)
            return 
    null;

        if(
    vInterval == "D")
            return 
    null;
            
        if(
    vInterval == "W")
            return 
    null;
            
        if(
    vInterval == "M")
            return 
    null;
            
        if(
    vInterval == "T")
            return 
    null;

        
    vBarTime getValue("time");
        if(
    vBarTime != null) {
            var 
    vDay vBarTime.getDay();
            if (
    vDay == 0) {
                var 
    vDate vBarTime.getDate();
                
    vDate -= 2;
                
    vBarTime.setDate(vDate);
            }
              
    vAbsTime getPreviousTradingDay(vBarTimevSymbol);
            if(
    vAbsTime == null) {
                return;
            }
            
    vIndex getFirstBarIndexOfDay(vAbsTimevSymbol);
            if(
    vIndex != null) {
                
    vH getValueAbsolute("High"vIndexvSymbol);
                
    vL getValueAbsolute("Low",  vIndexvSymbol);
                
    vO getValueAbsolute("Open"vIndex+1vSymbol);
                if(
    vH != null && vL != null && vO != null) {
                    
    vLastPP = (vH vL + (vO*2)) / 4;
                    
    vLastPPR1 vLastPP vL;
                    
    vLastPPS1 vLastPP vH;
                    
    vLastPPR2 = (vLastPP vLastPPS1) + vLastPPR1;
                    
    vLastPPS2 vLastPP - (vLastPPR1 vLastPPS1);
                    
    vLastPPR3 = (vLastPP vLastPPS2) + vLastPPR2;
                    
    vLastPPS3 vLastPP - (vLastPPR2 vLastPPS2);
                    
    vLastRawTime vRawTime;
                    
    vLastArray = new Array(vLastPPR3,vLastPPR2vLastPPR1vLastPPvLastPPS1vLastPPS2,vLastPPS3);

                    return 
    vLastArray;
                }
            } 
        }
        return 
    null;

    Regards,
    Jay F.
    Product Manager
    _____________________________________
    Have a suggestion to improve our products?
    Click Support --> Request a Feature in eSignal 11
Working...
X