Jump to content

(REQ) JFC Entry Point Indicator


zoom

Recommended Posts

  • 5 years later...
  • 10 months later...
  • 8 months later...

Pivot Function

 

inputs:

PriceValue( numericseries ),

Len( numericsimple ),

LeftStrength( numericsimple ),

RightStrength( numericsimple ),

Instance( numericsimple ),

HiLo( numericsimple ),

oPivotPriceValue( numericref ),

oPivotBar( numericref ) ;

 

variables:

var0( 0 ),

var1( 0 ),

var2( 0 ),

var3( 0 ),

var4( false ),

var5( false ) ;

 

var3 = 0 ;

var5 = false ;

var1 = RightStrength ;

while var1 < Len and var5 = false

begin

 

 

var0 = PriceValue[var1] ;

var4 = true ;

 

var2 = var1 + 1 ;

while var4 = true and var2 - var1 <= LeftStrength

begin

condition1 = ( HiLo = 1 and var0 < PriceValue[var2] )

or ( HiLo = -1 and var0 > PriceValue[var2] ) ;

 

if condition1 then

var4 = false

else

var2 = var2 + 1 ;

end ;

 

 

var2 = var1 - 1 ;

while var4 = true and var1 - var2 <= RightStrength

begin

condition1 = ( HiLo = 1 and var0 <= PriceValue[var2] )

or ( HiLo = -1 and var0 >= PriceValue[var2] ) ;

 

if condition1 then

var4 = false

else

var2 = var2 - 1 ;

end ;

 

if var4 = true then

var3 = var3 + 1 ;

 

 

if var3 = Instance then

var5 = true

else

var1 = var1 + 1 ;

end ;

if var5 = true then

begin

oPivotPriceValue = var0 ;

oPivotBar = var1 + ExecOffset ;

Pivot = 1 ;

end

else

begin

oPivotPriceValue = -1 ;

oPivotBar = -1 ;

Pivot = -1 ;

end ;

 

SWINGLOWBAR FUNCTION

 

inputs:

Instance( numericsimple ),

PriceValue( numericseries ),

Strength( numericsimple ),

Len( numericsimple ) ;

 

variables:

var0( 0 ),

var1( 0 ) ;

 

Value1 = Pivot( PriceValue, Len, Strength, Strength, Instance, -1, var0,

var1 ) ;

 

SwingLowBar = var1 ;

 

SWINGHIGHBAR FUNCTION

 

inputs:

Instance( numericsimple ),

PriceValue( numericseries ),

Strength( numericsimple ),

Len( numericsimple ) ;

 

variables:

var0( 0 ),

var1( 0 ) ;

 

Value1 = Pivot( PriceValue, Len, Strength, Strength, Instance, 1, var0,

var1 ) ;

 

SwingHighBar = var1 ;

 

JFC ENTRY POINT INDICATOR

 

Inputs: Sens(2);

 

BEGIN

IF SwingHighBar (1, HIGH, Sens, (Sens+1)) = Sens THEN

BEGIN

PLOT1[sens] (HIGH[sens], "Resistance") ;

END ;

 

IF SwingLowBar (1, LOW, Sens, (Sens+1)) = Sens THEN

BEGIN

PLOT2[sens] (LOW[sens], "Support") ;

END ;

 

END ;

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...