sereja К
sereja К личный блог
27 августа 2018, 12:30

Поиск баз (проторговок) в Thinkorswim TOS

<strong>#Ищет базу на любых уровнях.</strong>
#Cнять галочку Include Extended Session
#Thinkorswim  https://RadchenkoVY.com/TOS


def iDiff = 0.00; #максимальное отклонение в центах
def iBars = 4; #число баров для просмотра
def iLowest = lowest(low,iBars);
def iHighest = highest(high,iBars);
def bBaseLow = fold Lbar = 0 to iBars with Ls=1 do if ((low[Lbar]-iLowest)<=iDiff) then Ls*1 else Ls*0;
def bBaseHigh = fold Hbar = 0 to iBars with Hs=1 do if ((iHighest-high[Hbar])<=iDiff) then Hs*1 else Hs*0;
plot bBase = if bBaseLow then 1 else if bBaseHigh then 2 else 100;
AssignBackgroundColor (if (bBase == 1) then Color.LIGHT_GREEN else if (bBase == 2) then Color.LIGHT_RED else Color.black);
bBase.AssignValueColor (if bBase <> 100 then Color.black else Color.CURRENT);

Поиск баз (проторговок) в Thinkorswim TOS



<strong>#Ищет базу на уровнях кратным 50 центам.</strong>
#Cнять галочку Include Extended Session
#Thinkorswim  https://RadchenkoVY.com/TOS

def iDiff = 0.00; #максимальное отклонение в центах
def iBars = 4; #число баров для просмотра
def iLowest = lowest(low,iBars);
def iHighest = highest(high,iBars);
def bBaseLow = fold Lbar = 0 to iBars with Lsumm=1 do if  ((low[Lbar]-iLowest)<=iDiff) then Lsumm*1 else Lsumm*0;
def bBaseHigh = fold Hbar = 0 to iBars with Hsumm=1 do  if ((iHighest-high[Hbar])<=iDiff) then Hsumm*1 else  Hsumm*0;
def iFigureLow = fold FLbar = 1 to iBars+1 with FLsumm  do if (low[FLbar] == (Floor(low[FLbar]*2))/2) then  FLsumm+1 else FLsumm;                  
def iFigureHigh = fold FHbar = 1 to iBars+1 with FHsumm  do if (high[FHbar] == (Ceil(high[FHbar]*2))/2) then  FHsumm+1 else FHsumm;
plot bBase = if (bBaseLow and iFigureLow) then 1 else if  (bBaseHigh and iFigureHigh) then 2 else 100;
AssignBackgroundColor (if (bBase == 1) then Color.LIGHT_GREEN else if (bBase == 2) then Color.LIGHT_RED else Color.black);
bBase.AssignValueColor (if bBase <> 100 then Color.black else Color.CURRENT);
Поиск баз (проторговок) в Thinkorswim TOS


<strong>#Ищет базу, на уровнях 10-20-30 и т.д.</strong>
#Cнять галочку Include Extended Session
#Thinkorswim  https://RadchenkoVY.com/TOS

def iDiff = 0.00; #максимальное отклонение в центах
def iBars = 4; #число баров для просмотра
def iLowest = lowest(low,iBars);
def iHighest = highest(high,iBars);
def bBaseLow = fold Lbar = 0 to iBars with Lsumm=1 do if  ((low[Lbar]-iLowest)<=iDiff) then Lsumm*1 else Lsumm*0;
def bBaseHigh = fold Hbar = 0 to iBars with Hsumm=1 do  if ((iHighest-high[Hbar])<=iDiff) then Hsumm*1 else  Hsumm*0;         
def iLevelLow = fold LLbar = 0 to iBars with LLsumm  do if (low[LLbar] == roundDown(low[LLbar],1)) then LLsumm+1 else LLsumm;
def iLevelHigh = fold LHbar = 0 to iBars with LHsumm  do if (high[LHbar] == roundUp(High[LHbar],1)) then LHsumm+1 else LHsumm;
plot bBase = if (bBaseLow and iLevelLow ) then 1 else if (bBaseHigh and iLevelHigh ) then 2 else 100;
AssignBackgroundColor (if (bBase == 1) then Color.GREEN else if (bBase == 2) then Color.RED else Color.black);
Поиск баз (проторговок) в Thinkorswim TOS


Полная библиотека индикаторов, фильтров и сканеров для Thinkorswim в этом блоге  http://bit.ly/2vKq4F8
0 Комментариев

Активные форумы
Что сейчас обсуждают

Старый дизайн
Старый
дизайн