# A question for the Pin Bar Candle lovers :)

212

Hi friends

what is the best method to find a Pin Bar Candle , no matter Bearish or Bullish Pin Bar ?

39054

yassin.mokni:

Hi friends

what is the best method to find a Pin Bar Candle , no matter Bearish or Bullish Pin Bar ?

What have you tried ?
212

angevoyageur:
What have you tried ?
I tried this one

```// Bearish Pinbar
if(High[i]-High[i+1]>=NoseLength*NoseProtruding) // Nose protrusion
{
if(NoseBody/NoseLength<=MaxNoseBodySize) // Nose body to candle length ratio
{
if(1 -(High[i]-MathMax(Open[i],Close[i]))/NoseLength<NoseBodyPosition) // Nose body position in bottom part of the bar
{
if((!LeftEyeOppositeDirection) || (Close[i+1]>Open[i+1])) // Left Eye bullish if required
{
if((!NoseSameDirection) || (Close[i]<Open[i])) // Nose bearish if required
{
if(LeftEyeBody/LeftEyeLength>=LeftEyeMinBodySize) // Left eye body to candle length ratio
{
if((MathMax(Open[i],Close[i])<=High[i+1]) && (MathMin(Open[i],Close[i])>=Low[i+1])) // Nose body inside Left Eye bar
{
if(NoseBody/LeftEyeBody<=NoseBodyToLeftEyeBody) // Nose body to Left Eye body ratio
{
if(NoseLength/LeftEyeLength>=NoseLengthToLeftEyeLength) // Nose length to Left Eye length ratio
{
if(Low[i]-Low[i+1]>=LeftEyeLength*LeftEyeDepth) // Left Eye low is low enough
{
if((!NoseBodyInsideLeftEyeBody) || ((MathMax(Open[i],Close[i])<=MathMax(Open[i+1],Close[i+1])) && (MathMin(Open[i],Close[i])>=MathMin(Open[i+1],Close[i+1])))) // Nose body inside Left Eye body if required
{
Down[i]=High[i]+5*Point+NoseLength/5;
if(i==1) SendAlert("Bearish"); // Send alerts only for the latest fully formed bar
}
}
}
}
}
}
}
}
}
}
}
```

the same thing for the bullish pin bar
39054

This time I edited for ou.
212

angevoyageur:
This time I edited for ou.

:) , I comment from the mobile , that's why ... that menu didn't appear in the mobile version .

Have you  another method , a shorter one ?