Get Updates:
Email
Twitter
RSS

Here’s a reader request for an upper study that plots Fisher Transform signals on the price bars.

Fisher Transform Signals

Fisher Transform Signals


# FisherTransformSignals
# (c) 2009 http://www.thinkscripter.com
# thinkscripter@gmail.com
# Last Update 07 Mar 2009

input signalOffsetFactor = 0.20;
input length = 10;

def signalOffset = AvgTrueRange(high,close,low,10)*signalOffsetFactor;

def maxHigh = Highest(high, length);
def minLow = Lowest(low, length);

rec value = if maxHigh - minLow == 0 then 0 else 0.66 * ((close - minLow) / (maxHigh - minLow) - 0.5) + 0.67 * value[1];

def truncValue = if value > 0.99 then 0.999 else if value < -0.99 then -0.999 else value;

rec FT = 0.5 * (log((1 + truncValue) / (1 - truncValue)) + FT[1]);

def trendDown = if FT<FT[1] and FT[1]>FT[2] then 1 else 0;
def trendUp = if FT>FT[1] and FT[1]<FT[2] then 1 else 0;

plot signal = if trendUp then low-signalOffset else if trendDown then high+signalOffset else double.nan;

signal.setDefaultColor(color.white);
signal.setLineWeight(4);
signal.setStyle(curve.points);
signal.setpaintingStrategy(paintingStrategy.LINE_VS_SQUARES);

plot signalHighlight = signal;
signalHighlight.AssignValueColor(if trendUp then color.green else color.red);
signalHighlight.setLineWeight(1);
signalHighlight.setStyle(curve.points);
signalHighlight.setpaintingStrategy(paintingStrategy.LINE_VS_TRIANGLES);

5 Responses to “Fisher Transform Signals”

  1. traderwith says:

    Long live the Fish!! An already Great study mixed and refurbished by a great study creator equals Awesome!

    Great Study, Eric and thanks..

  2. Brad says:

    You do not cease to amaze me, your charts are incredible!

  3. thinkscripter says:

    Brad,
    Thanks. Hold on to your hat because I have a few in the pipeline which are far more ambitious and have been in development for weeks. I won’t release them until I’m satisfied they meet my standards.
    -TS

  4. rick forno says:

    Brilliant! I have been using the Fish for several months and it’s the only lower-level indicator I have on my charts right now. This is a handy addition to my “toolkit” and I doff my hat in your honor for being a great TosScripter!!

  5. rick forno says:

    Question – is there an easy condition in Thinkscript to only show Fish Signals above or below a certain threshold? IE, only show long/short if the cross occurs above or below +2/-2? IMHO that is where the Fish truly shines as a signal to exit or enter a trade as appropriate.

    I’d think it’d be a simple IF-THEN condition in ThinkScript, but I’m still learning my way around it.

Leave a Reply