-
RECENT POSTS
-
By Balazs Horvath · Posted
Hi, I am a newby and trying to write scripts in my DAS pro trial version (14-day trial). I went through the DAS video series on BBT site and downloaded a couple of the scripts available, but I haven’t found the one I was really looking for: fixed entry amount (like $10,000) at ask +0.05 with a fixed amont of stop-loss (like $100). I made a script with ChatGPT and tested it in the replay mode but it didn’t work properly. Chat GPT says it’s because the replay mode doesn’t support trigger orders. Anyways, here is the script I tried: Price=Ask+0.05; DefShare=10000/Price; Share=DefShare; RiskPerShare=100/Share; StopPrice=Price - RiskPerShare; ROUTE=LIMIT; TIF=DAY+; BUY=Send; TriggerOrder=RT:STOP STOPTYPE:MARKET PX:StopPrice ACT:SELL QTY=Share TIF:DAY+ WAIT=Send Can anyone help what is wrong with it? (Or there is no problem, just DAS replay mode doesn’t support trigger orders as Chat GPT said) Thanks for your reply! -
By John Evans · Posted
Hello everyone, My name is John Evans, I am currently residing in Wilmington, Delaware. I found an interest in trading the markets about one year ago, and have been absorbing as much information as I can in order to improve my skillset. I initially began with longer term investing in stocks, bonds, and ETF's, however, as I continued my research, I found day trading to be very interesting, and exciting. Once I made this discovery, I have been focused solely on improving this area of my trading knowledge. I stumbled upon Andrew's book 'How to Day Trade for a Living' and that led me to this platform. I hope to get to know some of you, and would be very interested in sharing ideas, and strategies over time. Feel free to contact me if you're local to me, or are simply interested in chatting more about trading. Have a great day! -
By lucian_dinu · Posted
The scripts bellow are for LONG and SHORT, in the particular case bellow Fixed risk is 10$, (described in the script as Share=10/Price, if you want 30$ risk, change 10 to 30 ) You will choose the Stop on the Chart, Press or Execute Hotkey/script, automatically an order with assigned fixed risk will be sent to be filled, once filled automatically a range order will be placed for STOP at the price chosen on the chart and Take Profit at 2x the Risk (price difference between Average Price and STOP) Basically this is a script with stop at 1R chosen on the chart and Take Profit at 2R ---------------------------- For LONGS: How you should use it(same for shorts): 1. Double Click on the Chart for the Stop Price 2. Press Hotkey For the Long Position Risk 10$ 3. Hotkey Script will send order with the Assigned risk ($10 in this case,) will calculate the number of shares automatically for you 4. The Script will create a "range order": place a Stop order where you've double clicked on the chart and a Take Profit / TP order at 2x the risk (Risk /Reward - 1/2) If you would like to change the reward to 3, or other multiples, chance the part of the script "Price=Price*2" to Price=Price*3 for example of 3Reward --------------------------- LONG Side Script StopPrice=Price;Price=Ask-Price;Share=10/Price;ROUTE=LIMIT;Price=Ask+.05;TIF=DAY+;BUY=Send; StopPrice=StopPrice;Price=Ask-StopPrice;Price=Price*2;Price=Ask+Price;Price=Round2; TriggerOrder=RT:STOP STOPTYPE:RANGE LowPrice:StopPrice HighPrice:Price ACT:SELL QTY:POS TIF:DAY+; _______________________ SHORT Side Script StopPrice=Price;Price=Price-Bid;Share=10/Price;ROUTE=LIMIT;Price=Bid-.05;TIF=DAY+;SELL=Send; StopPrice=StopPrice;Price=StopPrice-Bid;Price=Price*2;Price=Bid-Price;Price=Round2; TriggerOrder=RT:STOP STOPTYPE:RANGE LowPrice:Price HighPrice:StopPrice ACT:BUY QTY:POS TIF:DAY+; -------------------------------------------------- ! Always test any scripts and hotkeys in DEMO account prior to using them in real account with real money. -
By lucian_dinu · Posted
The Think or Swim / TOS Script /Code bellow will display a label into the volume box, showing the value of Daily ATR versus current Day ATR and % of the Daily ATR achieved in the current session / Day. Pictures attached for reference. Bellow are two versions of the script 1. Label is GREY under 70% DATR , Turns Green over 70% of the DATR, tuns RED over 100% DATR 2. Label is GERY under 70% DATR , Turns Green over 70% of the DATR 1.st Version -------Label is GREY under 70% DATR , Turns Green over 70% of the DATR, tuns RED over 100% DATR # ---------------------------------------------------------- # DATR vs Today-ATR – volume-pane label # DATR = 14-day Wilders-smoothed TrueRange from DAILY bars # ATS = today’s intraday High – Low # ---------------------------------------------------------- declare on_volume; input dailyATRLength = 14; input averageType = AverageType.WILDERS; # ---------- Daily ATR (computed from daily bars) ---------- def dailyTR = TrueRange( high(period = AggregationPeriod.DAY), close(period = AggregationPeriod.DAY), low(period = AggregationPeriod.DAY) ); def dailyATR = MovingAverage(averageType, dailyTR, dailyATRLength); # ---------- Today’s session range ---------- def todayHi = high(period = AggregationPeriod.DAY); def todayLo = low(period = AggregationPeriod.DAY); def todayATR = todayHi - todayLo; # ---------- Percentage ---------- def pct = if dailyATR != 0 then Round((todayATR / dailyATR) * 100, 1) else 0; # ---------- Label ---------- AddLabel( yes, "DATR " + Round(dailyATR, 2) + " vs ATR " + Round(todayATR, 2) + " (" + pct + "%)", if pct >= 100 then Color.GREEN else if pct >= 70 then Color.YELLOW else Color.GRAY ); 2.nd Version ------- Label is GERY under 70% DATR , Turns Green over 70% of the DATR # ---------------------------------------------------------- # DATR vs Today-ATR – volume-pane label # DATR = 14-day Wilders-smoothed TrueRange from DAILY bars # ATS = today’s intraday High – Low # ---------------------------------------------------------- declare on_volume; input dailyATRLength = 14; input averageType = AverageType.WILDERS; # ---------- Daily ATR (computed from daily bars) ---------- def dailyTR = TrueRange( high(period = AggregationPeriod.DAY), close(period = AggregationPeriod.DAY), low(period = AggregationPeriod.DAY) ); def dailyATR = MovingAverage(averageType, dailyTR, dailyATRLength); # ---------- Today’s session range ---------- def todayHi = high(period = AggregationPeriod.DAY); def todayLo = low(period = AggregationPeriod.DAY); def todayATR = todayHi - todayLo; # ---------- Percentage ---------- def pct = if dailyATR != 0 then Round((todayATR / dailyATR) * 100, 1) else 0; # ---------- Label ---------- AddLabel( yes, "DATR " + Round(dailyATR, 2) + " vs ATR " + Round(todayATR, 2) + " (" + pct + "%)", if pct >= 70 then Color.GREEN else Color.GRAY );
-