FSST

ICE Data Services -

FSST.efs  
EFSLibrary - Discussion Board  

File Name: FSST.efs

Description:
This Indicator plots FSST indicator

Formula Parameters:

  • BuyZone : 50

Notes:
FSST is the another modification of FSK indicator. It uses RSI and SLowK in the calculation.
The FSST is constructed from five different parts. The Kurtosis, the Fast Kurtosis(FK), the Fast/Slow Kurtosis(FSK), FSRS and Weighted FSRS.

Download File:
FSST.efs


EFS Code:

/*********************************
Provided By:  
    eSignal (Copyright c eSignal), a division of Interactive Data 
    Corporation. 2008. All rights reserved. This sample eSignal 
    Formula Script (EFS) is for educational purposes only and may be 
    modified and saved under a new file name.  eSignal is not responsible
    for the functionality once modified.  eSignal reserves the right 
    to modify and overwrite this EFS file with each new release.

Description:        
    This Indicator plots FSST indicator
    
Version:            1.0  01/19/2009

Formula Parameters:                     Default:
    BuyZone                             50

Notes:
    FSST is the another modification of FSK indicator. It uses RSI and SLowK in the calculation.
    The FSST is constructed from five different parts. The Kurtosis, the Fast Kurtosis(FK), 
    the Fast/Slow Kurtosis(FSK), FSRS and Weighted FSRS.

**********************************/

var fpArray = new Array();
var bInit = false;

function preMain() {
    setStudyTitle("FSST");
    setCursorLabelName("FSST", 0);
    setCursorLabelName("WMAFSST", 1);
    setDefaultBarFgColor(Color.blue, 0);
    setDefaultBarFgColor(Color.red, 1);
    
    var x=0;
    fpArray[x] = new FunctionParameter("BuyZone", FunctionParameter.NUMBER);
	with(fpArray[x++]){
        setLowerLimit(1);		
        setDefault(50);
    }
}

var xMOM_R = null;
var xMOM_RWAvr = null;
var xFastD = null;
var xFSST = null;
var xFSST_WAvr = null;

function main(BuyZone){
var nState = getBarState();

    if (nState == BARSTATE_ALLBARS) {
        if (BuyZone == null) BuyZone = 50;
    }
    
    if ( bInit == false ) { 
        xMOM_R = mom(1, mom(3));
        xMOM_RWAvr = wma(6, ema(65, xMOM_R));
        xFastD = efsInternal("Calc_FastD", upperDonchian(9), lowerDonchian(9));
        xFSST = efsInternal("Calc_FSST", xMOM_RWAvr, xFastD);
        xFSST_WAvr = wma(9, xFSST);
        
        addBand(BuyZone, PS_SOLID, 2, Color.green, "0");
        bInit = true; 
    } 

    return new Array(xFSST.getValue(0), xFSST_WAvr.getValue(0));
}

function Calc_FSST(xmom, xfastd){
    var nVal4 = xmom.getValue(0);
    if (nVal4 == null) return;    
    var nFastD = xfastd.getValue(0);
    var nVal5 = 500 * nVal4 + nFastD;
    return nVal5;
}

function Calc_FastD(xHH, xLL) {
var nRes = 0;
var nRef = ref(-1);
var nValueLL = xLL.getValue(0)
var nValue = xHH.getValue(0) - nValueLL;
var FastK = 0;
    if (nValue == null) return;
    if (nValue > 0) {
        FastK = (close(0) - nValueLL) / nValue * 100;
    }
    nRes = nRef + (0.5 * (FastK - nRef));
    if (nRes == null) nRes = 1;
    return nRes;
}