Welcome to the Traders Laboratory Forums.
Coding Forum Collaborate, receive help, or discuss coding related issues.

Reply
Old 11-30-2009, 06:00 PM   #65

Join Date: Nov 2009
Location: Washington D.C.
Posts: 4
Ignore this user

Thanks: 0
Thanked 0 Times in 0 Posts

Re: Think or Swim Code/indicators

I'm not too sure what you guys are talking about, but if your looking for the tick and/or makret profile TOS has that already built in. Letme know if thats what your looking for and I'll let you know how to find it
WCMcKee87 is offline  
Reply With Quote
Old 01-13-2010, 11:35 AM   #66

Join Date: Dec 2008
Location: new york
Posts: 33
Ignore this user

Thanks: 0
Thanked 2 Times in 2 Posts

Re: Think or Swim Code/indicators

there are a bunch of free indicators, links and resources here:

Custom Thinkscript Indicators
HI_THERE is offline  
Reply With Quote
Old 02-19-2010, 12:42 PM   #67

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

some stuff i coded....
scalps for 15 min chart
----------------------------------------

declare lower;
declare zerobase;
input length = 50;
input size = 2.5;

plot body = if ((absvalue(close-open)) >= size) then absvalue(close-open) else 0;
#absvalue (close-open) ;
plot bodyAvg = Average((absvalue(close-open)), length);


plot after = if
((absvalue(close[1]-open[1])) >= size)
and
( (absvalue(close[1]-open[1])) / (absvalue(close-open)) ) >=2 then
( (absvalue(close-open)) ) else 0;
after.SetPaintingStrategy (PaintingStrategy.HISTOGR AM);
after.SetDefaultColor(Get Color(2));


plot dwnreverse = if
(close[1] < open[1]) and
((absvalue(close[1]-open[1])) >= size)
and
( close > ( ((absvalue (close[1]-open[1]))/2)+ close[1]))
then
(absvalue(close-open)) else 0;
dwnreverse.SetPaintingStr ategy(PaintingStrategy.HI STOGRAM);
dwnreverse.SetDefaultColo r(GetColor(6));


plot upreverse = if
(close[1] > open[1]) and
((absvalue(close[1]-open[1])) >= 2)
and
( close < ( (close[1]) - ((absvalue (close[1]-open[1]))/2) ))
then
(absvalue(close-open)) else 0;
upreverse.SetPaintingStra tegy(PaintingStrategy.HIS TOGRAM);
upreverse.SetDefaultColor (GetColor(5));



body.SetPaintingStrategy( PaintingStrategy.HISTOGRA M);
body.DefineColor("Up", Color.yellow);
body.DefineColor("Down", Color.blue);

body.AssignValueColor(if close > close[1] then body.color("Up") else if close < close[1] then body.color("Down") else GetColor(1));
bodyAvg.SetDefaultColor(G etColor(8));
elovemer is offline  
Reply With Quote
Old 02-19-2010, 12:42 PM   #68

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

reversal signal

------------------------------------



input signalOffsetFactor = 0.20;
def signalOffset = AvgTrueRange(high,close,l ow,9)*signalOffsetFactor;

input price = close;
def triggerSell =
(close[1] > open[1]) and
((absvalue(close[1]-open[1])) >= 1)
and
( close < ( (close[1]) - ((absvalue (close[1]-open[1]))/2) ))
;
#--------------------------------
def triggerBuy = (close[1] < open[1]) and
((absvalue(close[1]-open[1])) >= 1)
and
( close > ( ((absvalue (close[1]-open[1]))/2)+ close[1]))
;

#-----------------------------------------
#plot SBS = if (triggerSell , high+signaloffset, if (triggerBuy, low-signaloffset, double.nan) );
plot uSBS = if (triggerSell, high+signaloffset, double.nan);
plot dBS = ( if (triggerBuy, low-signaloffset, double.nan) );


uSBS.SetStyle(curve.POINT S);
uSBS.SetPaintingStrategy( paintingStrategy.LINE_VS_ SQUARES);
uSBS.SetLineWeight(2);
uSBS.SetDefaultColor(colo r.blue);

dBS.SetStyle(curve.POINTS );
dBS.SetPaintingStrategy(p aintingStrategy.LINE_VS_S QUARES);
dBS.SetLineWeight(2);
dBS.SetDefaultColor(color .blue);
elovemer is offline  
Reply With Quote
Old 02-19-2010, 12:43 PM   #69

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

demand
-------------------------------

declare lower;
input ATRLength = 14;
#plot ATR = AbsValue(close - open);
plot ATR = if ((close-open)<0) then ((volume)/ABSVALUE(close-open))
else 0;

ATR.SetDefaultColor(GetCo lor(8));
ATR.SetPaintingStrategy(P aintingStrategy.HISTOGRAM );
ATR.DefineColor("Positive ", Color.green);
ATR.DefineColor("Negative ", Color.red);
ATR.AssignValueColor(if
(close - open) > 0
then ATR.color("Positive") else ATR.color("Negative"));
elovemer is offline  
Reply With Quote
Old 02-19-2010, 12:44 PM   #70

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

supply
----------------------

declare lower;
input ATRLength = 14;
#plot ATR = AbsValue(close - open);
plot ATR = if ((close-open)>0) then ((volume)/(close-open))
else 0;

ATR.SetDefaultColor(GetCo lor(8));
ATR.SetPaintingStrategy(P aintingStrategy.HISTOGRAM );
ATR.DefineColor("Positive ", Color.green);
ATR.DefineColor("Negative ", Color.red);
ATR.AssignValueColor(if
(close - open) > 0
then ATR.color("Positive") else ATR.color("Negative"));
elovemer is offline  
Reply With Quote
Old 02-19-2010, 12:46 PM   #71

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

decrease in pivot range
--------------------------------------

declare lower;
input ATRLength = 14;

def HA = high[1];
def HB = high[2];
def HC = high[3];
def LA = low[1];
def LB = low[2];
def LC = low[3];
def C = close[1];
def H3 = Max(Max(HA, HB), HC);
def L3 = Min(Min(LA, LB), LC);
Def calc_PP = (H3 + L3 + C) / 3;
def calc_MP = (H3 + L3) / 2;
def calc_PR = AbsValue(calc_PP - calc_mp);

def calc_PH = Calc_PP + calc_PR;
def calc_PL = Calc_PP - calc_PR;

plot ATR = -
( (absvalue(calc_PH-calc_PL))- (absvalue(calc_PH[1]-calc_PL[1]))
);
#plot ATR =1/(AbsValue(calc_PH - calc_PL)) ;
#def hum = (AbsValue(calc_PH - calc_PL)) ;

ATR.SetDefaultColor(GetCo lor(8));
ATR.SetPaintingStrategy(P aintingStrategy.HISTOGRAM );
ATR.DefineColor("Positive ", Color.gray);
ATR.DefineColor("Negative ", Color.green);
ATR.AssignValueColor(if
#HUM
ATR < 0
then ATR.color("Positive") else ATR.color("Negative"));
elovemer is offline  
Reply With Quote
Old 02-19-2010, 12:47 PM   #72

Join Date: Jan 2008
Location: africa
Posts: 1,110
Ignore this user

Thanks: 46
Thanked 75 Times in 58 Posts
Blog Entries: 6

Re: Think or Swim Code/indicators

volume by body by range
--------------------------------

declare lower;
input ATRLength = 14;
#plot ATR = AbsValue(close - open);
#plot ATR = ((volume)/(absvalue(close-open)));
plot ATR = volume / ((absvalue(close-open))/(absvalue(high-low)));

ATR.SetDefaultColor(GetCo lor(8));
ATR.SetPaintingStrategy(P aintingStrategy.HISTOGRAM );
ATR.DefineColor("Positive ", Color.green);
ATR.DefineColor("Negative ", Color.red);
ATR.AssignValueColor(if
(close - open) > 0
then ATR.color("Positive") else ATR.color("Negative"));
elovemer is offline  
Reply With Quote

Reply

Thread Tools
Display Modes Help Others By Rating This Thread
Help Others By Rating This Thread:


Similar Threads
Thread Thread Starter Forum Replies Last Post
TTM Indicators for CQG? bathrobe Coding Forum 3 01-03-2011 06:01 AM
TradeStation Strategy Code Help jjthetrader Coding Forum 2 10-26-2010 08:06 AM
TTM trend esignal code philloo Trading Indicators 9 04-16-2009 09:51 AM
Does Anyone have the TTM Scalper Code for Esignal??? jphillips9 Beginners Forum 5 01-14-2008 07:26 PM
Floor Trader Pivot Code Help.... jmi88 Coding Forum 1 05-22-2007 10:13 PM

All times are GMT -4. The time now is 11:37 AM.
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
CS to VB integration by DeskLancer
©2006-2011 Traders Laboratory, All Rights Reserved.