Advertisement
jcseattle

Untitled

Jan 18th, 2018
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 28.76 KB | None | 0 0
  1. ------- Thursday, January 18, 2018 -------
  2. 03:35 Nube: .
  3. 05:18 Up2: Gd everyone. Does anyone have a Donchian Channel script?
  4. 05:23 Paris: Up2 - DonChian Channel is also commonly known as Price Channels, should be available as a standard TOS study
  5. 05:23 Up2: Thank you Paris!
  6. 05:24 steveand: Guys im trying to find a scanner than can give me tikers within a percentage of an EMA on the daily, anyone have something they can share? Thanks
  7. 05:26 Paris: steve - here is a simple example on how to scan for stocks with a close between 5-10% above the 10 SMA.
  8.  
  9. between(close, Average(close, 10) * 1.05, Average(close, 10) * 1.1)
  10. 05:30 Up2: Paris, how can a mid bar calculation be added to the Price channels?
  11. 05:30 Up2: ...midline...
  12. 05:30 DMonkey: input n = 20;
  13. def l = low;
  14. def h = high;
  15.  
  16. plot hh = highest(h,n);
  17. plot ll = lowest(l,n);
  18. plot median = (hh + ll) * .5;
  19. 05:32 Nube: crafty bugger multiplying by .5 instead of dividing by 2
  20. 05:33 Nube: I'm mathematically inept, so I divide.
  21. 05:33 Paris: Up2 - DM's solution will work just fine.
  22. 05:34 Up2: Thank you DM!
  23. 05:34 Paris: Here's a similar study that was posted several years ago
  24.  
  25.  
  26. # Price Channel Middle Band
  27. # zzz
  28. # 11.01.2015
  29.  
  30. #
  31. # TD Ameritrade IP Company, Inc. (c) 2007-2015
  32. #
  33.  
  34. input displace = 0;
  35. input length = 20;
  36.  
  37. plot LowerBand = Lowest(low[-displace + 1], length);
  38. LowerBand.SetDefaultColor(GetColor(1));
  39.  
  40. plot UpperBand = Highest(high[-displace + 1], length);
  41. UpperBand.SetDefaultColor(GetColor(1));
  42.  
  43. plot MidBand = (LowerBand + UpperBand)/2;
  44.  
  45. MidBand.AssignValueColor(if round(MidBand[1], 2) == round(MidBand, 2)
  46. then Color.YELLOW
  47. else if round(MidBand[1], 2) < round(MidBand, 2)
  48. then Color.DARK_GREEN
  49. else Color.DARK_RED);
  50. # End Study
  51. 05:36 Paris: Uou should be all set now
  52. 05:37 Mobius: Add a ZigZag to that and it'd be perfect
  53. 05:40 DMonkey: + zigzag
  54. 05:40 DMonkey: :)
  55. 05:41 Paris: DM might just attempt that as a challenge, LOL!
  56. 05:42 Nube: I can see it now, plot zigzag = fold z to ..
  57. 05:42 DMonkey: + enable approx
  58. 05:43 DMonkey: + fib
  59. 05:44 DMonkey: I'll make it cross a line somewhere.....
  60. 05:44 Nube: Now you're talking, get those fibs in there.
  61. 05:45 Nube: here's my contributing idea, don't call it a midline, call it Pointfivefib or some such
  62. 05:48 Shizznet: Guys
  63. 05:48 Shizznet: It’s too early for this
  64. 05:50 Nube: if getnetliq() crosses below pointfivefib then stop trading fibs
  65. 05:58 Nube: speaking of stop trading, I'm still actual paper trading an idea so I didn't hurt myself, but I learned overnight that I need to set more disciplined testing right from the start instead of going about it willy nilly until it looks like it's worth going through all that hard work of a spreadsheet. The horror. egads.
  66. 06:03 Nube: I had roughly zero confidence so what I did I do? "Ah, it's just paper still, I'll tighten up the stop" which is maybe the exact opposite of what a person should do. A more disciplined protocol doesn't fall the error.
  67. 06:08 Mobius: Nube - Follow what price does for stops. Price expands at the beginning of a traend and contracts at the end of a trend. Stops should be wider at the beginnig of a trend and narrower at the end.
  68. 06:09 Mobius: You will never get 100 of a trend as a rule. Shoot for 80% as a rule
  69. 06:10 Mobius: 60% will make you a reasonable return.
  70. 06:15 Nube: I've never been good with stop placement, but lasts tests was just flat out boneheaded.
  71. 06:16 DMonkey: you could put a damper switch in your trail that uses expansion and contraction so it will tighten up as ATR decreases.....
  72. 06:17 Nube: That advice gives me something to chew on. I generally give more room for volatility, but that's mostly the result of a local low being farther away, not any solid discipline.
  73. 06:23 Hey-U: Aloha Nube: "I've never been good with stop placement,..." May I suggest you read over TD Ameritrade "Parabolic SAR' and then install. Then google ... Parabolic SAR Great articles, etc. on the net. [ALSO Parabolic SAR stand for 'SAR = Stop And Reverse". Good Luck and Mahalo Lucky ;-)
  74. 06:25 Nube: So my buy stops are looser than my sell stops since price is more volatile there.
  75. 06:27 Hey-U: Aloha NUBE: All of the info you want will be revealed with Parabolic SAR... Try it = with Paper Trade... I think you'll like it. Lucky
  76. 06:28 Shizznet: Thanks, Hey-U.
  77. 06:34 Nube: Yeah, Hey-U, psar jives with the earlier advice to be loose early, tight late.
  78. 06:35 Mobius: PSAR is good in a trending market. It bites in a trading market unless you alter it's acceleration factor and limit method
  79. 06:38 Nube: I don't know how to get psar to not blend you in the chop, but can see it being a useful tool once you identify that you are in trend.
  80. 06:41 Nube: Reapplying psar and the end of each eci legacy plot might be a scripting project worth working on.
  81. 06:44 Mobius: Nube it is worthwhile. Rewrite PSAR to use the values in ECI. You will be pleased with it then.
  82. 06:55 Shizznet: :0
  83. 06:55 purealgo: Hello, I'm looking for a daily decile indicator. I'd like it to plot charts every 10th of the current day's range. Anyone know of anything?
  84. 07:03 Nube: I for one am shocked that Mobius already thought of that.
  85. 07:05 adrian0081: Mobius...How to rewrite PSAR and how to use its values in ECI ? What is ECI ?
  86. 07:07 adrian0081: Can you exemplify ?
  87. 07:07 Mobius: Nube Wilders came up with the PSAR in the mid 70's we knew then that the flaw in the system was that it needed constant adjustment for the factors added. It was a number of years after that, that someone started applying a voltility index to it. Then some time after that a linear algorithm. It's been used for a long time in that last state
  88. 07:08 Mobius: pure.. How do you want that displayed?
  89. 07:08 UpTheCreek: ECI is another of Mobius' contributionns to the room. Yoou can likely find it on his MyTrade page
  90. 07:09 Nube: Mobius does indeed exemplify a great many things
  91. 07:09 Paris: Mobius had written a script called ECI, short for expansion contraction indicator. It identifies areas of price compression which leads to price expansion. ECI doesn't show the direction of a trend but does indicate when a trend is going to resume (price flagging) or if a change in trend polarity is happening. Like UTC says you can find this on Mobius MyTrade
  92. 07:11 Nube: This also meams Mobius has already completed my latest project of tracking often the flags trends
  93. 07:12 adrian0081: Thanks
  94. 07:13 UpTheCreek: yes, but not the super critical decile range diagnostic tool ...yet
  95. 07:13 Mobius: Nube - ECI / Fractal Linear Energy - Range is 0 to 1. TOS PSAR acceleration Factor range is .01 to .1 and acceleration limit range is .1 to 1. All you need do to test if it's worthwhile diving deeper into is scale the basic FE to those ranges and replace the PSAR input values with the FE scaled values
  96. 07:15 UpTheCreek: very tasty breadcrumbs
  97. 07:15 Shizznet: What he said.
  98. 07:17 purealgo: cool thanks!
  99. 07:17 DMonkey: It's a good excercise Nube....I use FE to dampen and accelerate several things.....
  100. 07:19 chief: I believe Mobius wrote a script awhile back called ...PSAR Fractal Self Adjusting.
  101. 07:20 Shizznet: Noooooo
  102. 07:20 Shizznet: Link or it didn’t happen
  103. 07:21 chief: Not going to post unless Mobius says OK. Don't want to get in trouble with the master.
  104. 07:21 Nube: Sure, but was it an MTF fractal self adjusting psar.
  105. 07:21 Shizznet: with bubbles!
  106. 07:23 AlphaInvestor: and zig zags, and candy, and ice cream
  107. 07:23 Paris: Only one I foundfrom my notes was "Parabolic SAR modified with fractal dimension index"
  108. 07:24 Nube: For the sake of clarity, the gamma value in ECI is tick rounded. For those following along, I don't suspect the teachers are referring to that tick rounded value.
  109. 07:26 chief: Paris..This is in the header...# Parabolic SAR modified with fractal dimension index
  110. # Mobius
  111. # V01.01.2010 V02.09.2013 V03.07.2014 V04.2014
  112. 07:27 Paris: chief - seems like that's the version you were referring to.
  113. 07:27 Nube: Now we are talking about other dimensions. We've gotten way above my head quickly.
  114. 07:28 Paris: Posted way back in Nov 2015
  115. 07:29 Shizznet: The good ol' days
  116. 07:30 DMonkey: ECI range is between 0 & 1....
  117. 07:30 Up2: Paris/DM can the Donchian script you provided earlier have script added to reflect when 2 or more levels are up the color is light green, and when 2 or more levels are down the color is salmon?
  118. 07:32 Shizznet: Define "levels"
  119. 07:32 DMonkey: i don't know what 2 or more levels means to you, but the answer is yes....you can addcloud and color or you can assign price color....you pick the condition and how you want to color....
  120. 07:33 Shizznet: What is the distance between 1 and 2 levels
  121. 07:33 Shizznet: A mile or a foo
  122. 07:33 Shizznet: or a feet.
  123. 07:33 Shizznet: -_-
  124. 07:34 Paris: As they say in France, l'impossible n'est pas Francais, it is all a programming effort, all depends on your requirements ala DM's comment above.
  125. 07:34 Nube: Great. Now I gotta try the rounded and unrounded values. Stupid learning and stuff.
  126. 07:35 Up2: DM, I am ref the hi/lo/mid lines of the script.
  127. 07:36 Paris: You folks have a nice trading session, Time to snooze for a bit. Later
  128. 07:36 Shizznet: Have a good nap, Paris.
  129. 07:36 Shizznet: That's even more confusing
  130. 07:39 Up2: e.g. two of the three Dochian lines/levels are falling, So the color would turn salmon
  131. 07:39 Nube: up2, the midline is just along for the ride so whether that moves up or down might not be very helpful. Do you mean if the high or low move up or down?
  132. 07:43 Up2: Nube, if I understand correctly, then yes. and would need both upper and lower lines to agree for a color change. otherwise it would be neutral
  133. 07:45 Up2: this would be considered neutral, the upper level in declining and the lower level is rising
  134. 07:53 Nube: Up2, def hhstate = if hh > hh[1] then 1 else if hh hh[1] then 0 else hhstate[1];
  135. 07:54 Nube: do the same with the ll plot. When hhstate + llstate == 2 then you have the lines rising.
  136. 07:56 Up2: how do you add a cloud to that as DM ref
  137. 07:57 Nube: Where don't want to add the cloud?
  138. 07:59 Up2: pardon?
  139. 08:01 Nube: Where do you want the cloud to be?
  140. 08:02 Up2: if trending up between the mid and upper line, if trending down, between the mid and lower line.
  141. 08:06 Nube: addcloud(if (statesvalue == 2, hh, double.nan), midline, Color.green); that should get you started
  142. 08:08 Up2: The statement shows invalid def hhstate = if hh > hh[1] then 1 else if hh hh[1] then 0 else hhstate[1];
  143. def hhstate = if ll < ll[1] then h else if ll ll[1] then 0 else llstate[1];
  144. 08:16 Nube: That's two statements. which one is showing invalid?
  145. 08:17 Nube: perhaps both? they are missing operators and the second has additional problems. Are the operators in the study or are they missing there as well?
  146. 08:17 Up2: i think i fixed that part
  147. 08:17 Up2: def hhstate = if hh > hh[1] then 1 else if hh < hh[1] then 0 else hhstate[1];
  148. def llstate = if ll < ll[1] then 1 else if ll > ll[1] then 0 else llstate[1];
  149. 08:18 Nube: that looks much better
  150. 08:19 Up2: but i get errors here
  151. 08:19 Up2: AddCloud (If (statesvalue == 2, hh, Double.NaN), median, Color.GREEN);
  152. AddCloud (If (statesvalue == 2, ll, Double.NaN), median, Color.LIGHT_ORANGE);
  153. 08:20 Up2: statesvalue is highlighted as the issue
  154. 08:20 Up2: should that be substituted with something
  155. 08:20 Nube: because it's not defined. You need to define it.
  156. 08:21 Nube: hhstate + llstate
  157. 08:23 Up2: i thought the lines @ 11:17 defined hhstate and llstate?
  158. 08:26 Up2: still an invalid statement: AddCloud if hhstate == 2, hh, Double.NaN, median, Color.GREEN;
  159. 08:27 Shizznet: Did you define hhstate?
  160. 08:28 Shizznet: Do you know the output of hhstate currently?
  161. 08:28 Nube: you need to define statesvalue as the sum of hhstate and llstate
  162. 08:30 Up2: like this: def statesvalue = hhstate + llstate;
  163. 08:30 Nube: def statesvalue = hhstate + llstate;
  164. 08:30 Nube: Beat me to it. yep.
  165. 08:38 Up2: Ok, got rid of error, but not plot what is in mind. It should be one or the other or none if neutral From the far ledt it should be red all the way down and only shaded in the lower half
  166. 08:40 Up2: this is the code as it stands: input n = 20;
  167. def l = low;
  168. def h = high;
  169. plot hh = Highest(h, n);
  170. plot ll = Lowest(l, n);
  171. plot median = (hh + ll) * .5;
  172. def hhstate = if hh > hh[1] then 1 else if hh < hh[1] then 0 else hhstate[1];
  173. def llstate = if ll < ll[1] then 1 else if ll > ll[1] then 0 else llstate[1];
  174. def statesvalue = hhstate + llstate;
  175. AddCloud (If (statesvalue == 2, hh, Double.NaN), median, Color.LIGHT_GREEN);
  176. AddCloud (If (statesvalue == 2, ll, Double.NaN), median, Color.LIGHt_ORANGE);
  177. 08:43 Nube: use statesvalue == 0 in the orange one. additionally, you will also want to swap the ll and median in that one
  178. 08:50 Nube: one more thing, you have your operators backwards in the llstate definition. They need to be the same as hhstate since we want to know when both are doing to same thing
  179. 08:50 fredw: what is fractal energy?
  180. 08:51 fredw: I didn't know fractals have energy
  181. 08:52 AlphaInvestor: some have considerable energy, some are quite lazy
  182. 08:52 Shizznet: lol
  183. 08:53 AlphaInvestor: some fractals just wait around to see what their neighbors do
  184. 08:54 Nube: High energy and low energy fractals.
  185. 08:55 fredw: alpha guru must be drinking JD
  186. 08:56 AlphaInvestor: No, but my coffee is low, got to put on another pot
  187. 08:57 Mobius: fractal means: self similar. How do you determine when a self similar pattern is different?
  188. 08:58 fredw: is fractal energy like sinusoidal wave energy
  189. 08:58 Shizznet: Up2, I added a debug label to troubleshooting:
  190. input deBug = YES;
  191. input n = 20;
  192. def l = low;
  193. def h = high;
  194. plot hh = Highest(h, n);
  195. plot ll = Lowest(l, n);
  196. plot median = (hh + ll) * .5;
  197. def hhstate = if hh > hh[1] then 1 else if hh < hh[1] then 0 else hhstate[1];
  198. def llstate = if ll < ll[1] then 1 else if ll > ll[1] then 0 else llstate[1];
  199. def statesvalue = hhstate + llstate;
  200. AddCloud (If (statesvalue == 2, hh, Double.NaN), median, Color.LIGHT_GREEN);
  201. AddCloud (If (statesvalue == 2, ll, Double.NaN), median, Color.LIGHt_ORANGE);
  202.  
  203. addLabel(
  204. deBug,
  205. "L = " + L + " | " +
  206. "H = " + H + " | " +
  207. "HH = " + HH + " | " +
  208. "LL = " + LL + " | " +
  209. "Median = " + Median + " | " +
  210. "hhstate = " + hhstate + " | " +
  211. "llstate = " + llstate + " | " +
  212. "statesvalue = " + statesvalue
  213. ,Color.DARK_GRAY);
  214. 08:58 fredw: Mobius I don't know how
  215. 08:59 fredw: I don't understand
  216. 09:00 Mobius: you could say that there is a relationship between the time in a linear state and the energy of that state sure fred..
  217. 09:01 Cliff: Good morning Everyone how do I add PEG Ratio and Price to Sales ratio to my fundamentals filter
  218. 09:02 Mobius: is PEG ratio a fundamental filter?
  219. 09:04 AlphaInvestor: Cliff - PEG Rtatio is not availble in TOS - contact support and ask for it to be added (BE the squeaky wheel)
  220. 09:05 FrankB3: AI::: Mr. Scripts on trader_TV:: will be talking about buying bitcoin
  221. 09:05 Cliff: Well it is @mobius but I would put it any where long as i have it ill try @Alphainvestor
  222. 09:05 Mobius: What?
  223. 09:06 chief: This paragraph helped me to understand fractals a little better..#From article by Jeff Swanson .
  224. #The essence of self-similarity and complexity is to compare the whole to its component parts. For example, let’s take a square that is divided into four separate squares of equal size. The area of the larger square is equivalent to the sum of the areas of each of its component squares. The same of course is true of a one-dimensional line which is equivalent to the sum of its parts. One of the methods of identifying self-similarity in the stock market is to look at the range or the difference between the highs and the lows. We would expect that in a perfectly self-similar market the longer range would be equivalent to the sum of the ranges measured over a smaller interval. The more chaotic the market is, the greater the difference will be between these two measures. Such market conditions would be characterized by a large ratio between the sum of smaller ranges versus the longer measure of range. Essentially this relationship is called fractal dimension and is a measure of complexity. There are many different ways to measure this including using the Hurst exponent, but the problem I have always found in my own humble research is that the suggested thresholds defined by specific absolute values do not seem to reflect the information consistent with theory. I have often found that relative measures tend to be more robust and consistent – much the same way that the magnitude of past returns has less predictive value than the relative rank of past returns. Relative measures tend to be more stationary than absolute values. To compute this measure of self-similarity I use the intraday range (high minus low) versus a longer range window.
  225. 09:06 Cliff: a fundamental filter @mobius
  226. 09:07 AlphaInvestor: Frank - no thanks, I like David, but bitcoin is for bozo's
  227. 09:07 AlphaInvestor: Limbo time
  228. 09:07 FrankB3: just joking
  229. 09:08 AlphaInvestor: looks like he has SLM_Ribbons up
  230. 09:08 Cliff: bitcoin is for people that already had it a couple years ago @Alpha
  231. 09:09 harndog: SLM - more colors..
  232. 09:14 mark5512: Hello everyone. I need a really simple indicator coded. Can anyone help me pleeeeaaassseee? :)
  233. 09:16 Shizznet: Whatcha got, mark?
  234. 09:16 mark5512: I need a moving average that adds plus 1 after most recent candlestick close. For example, if I'm looking at a 25 period ma, the indicator will add 1 after each new candlebar so 25 will become 26 and so on.
  235. 09:16 Shizznet: lol
  236. 09:17 Shizznet: Only a constant allowed.
  237. 09:17 Up2: Thank you Shizznet, let me try it.
  238. 09:17 mark5512: What do you mean?
  239. 09:17 Shizznet: yw Up2.
  240. 09:17 Shizznet: That "MAlengthPeriod" you're asking for can only be a constant. Can't change without being an input
  241. 09:18 Shizznet: Are you trying to get a MA for the day or what?
  242. 09:19 mark5512: No I have one. I thought there was code that can do that automatially.
  243. 09:20 Mobius: yes mark that can be done
  244. 09:21 Nube: def total = total[1] + close; plot ma = total/barnumber();
  245. 09:22 mark5512: @Mobius...that would be great . WOuld you be able to help , me with that?
  246. 09:22 mark5512: @NUbe...I'll give it a try.
  247. 09:26 mark5512: @Nube... it doesnt give me the option to choose tha number operiod to start off with?
  248. 09:26 mark5512: I cant input anyting.
  249. 09:28 Nube: No, but you can add that.
  250. 09:29 mark5512: It does not give me the option to do so.
  251. 09:30 mark5512: WHen I go into the properties the input box is blank with no option to add anything.
  252. 09:30 Shizznet: Def != input
  253. 09:31 Nube: http://tlc.thinkorswim.com/center/howToTos.html
  254. 09:32 bigworm: Hey möbius I’m seeing a trend as I go through my pairs list. Seems like a lot of the pairs that cointegrate really well don’t always make the best pair to trade
  255. 09:32 mark5512: I have no coding experiece by the way.
  256. 09:32 bigworm: Is this similar to what you find
  257. 09:34 Mobius: mark - is this what your looking for
  258.  
  259. input length = 25;
  260. def average = Average(close, length);
  261. def n = compoundValue(length+1, n[1] + 1, 1);
  262. def sumValue = compoundValue(length+1, sumValue[1] + close, average);
  263. plot avg = if barNumber() > 25 then sumValue / n else average;
  264. 09:36 Mobius: big yes. cointegration is necessary but not the only factor in a good pair. Just the first factor
  265. 09:39 mark5512: @Mobius...the code doesnt function. I have the option for inputs but now nothing changes when it comes to the average if I change inputs.
  266. 09:41 Mobius: of course it functions. I wouldn't post it if it didn't work
  267. 09:41 bigworm: Ok cool I was just feeling uneasy when I see all these good cointegrating pairs but they don’t yield results
  268. 09:41 Mobius: the length ONLY alters the first period of Averages.
  269. 09:43 mark5512: Ok I got you. THank you very much Mobius. :)))
  270. 09:44 Mobius: This was your request
  271. I need a moving average that adds plus 1 after most recent candlestick close. For example, if I'm looking at a 25 period ma, the indicator will add 1 after each new candlebar so 25 will become 26 and so on.
  272.  
  273. If that's not what you want restate your request
  274. 09:46 mark5512: No that was it. YOu hit it right on the head. I didnt copy and paste it correctly. It works perfectly.
  275. 09:49 mark5512: Thank you verymuch sir.
  276. 09:49 Mobius: yw
  277. 09:53 Mackenzie: Do you guys have a study that would color /ES green when /YM is up and color /ES red when /YM is down? Thank you.
  278. 09:56 Shizznet: addVertical(if Close("/ym")>Open("/ym") then 1 else 0, "YM Green", Color.GREEN)
  279. addVertical(if Close("/ym")<Open("/ym") then 1 else 0, "YM Red", Color.RED
  280.  
  281. 09:57 Shizznet: Disclaimer: Coded in chat. Might see red errors.
  282. 10:01 Mackenzie: Shizznet: Thank you, but you're right, there're errors, so it doesn't plot. Sorry I don't know how to fix them.
  283. 10:02 fasxs: hello, could someone tell me how to change the clock from 24 hour to 12 hour please
  284. 10:04 Shizznet:
  285. addVerticalLine(if Close("/ym")>Open("/ym") then 1 else 0, "YM Green", Color.GREEN);
  286. addVerticalLine(if Close("/ym")<Open("/ym") then 1 else 0, "YM Red", Color.RED);
  287. 10:04 Shizznet: Mackenzie ^
  288. 10:05 Shizznet: And if you want to learn a little, you can compare both scripts I provided and notice the changes I made to "fix" it.
  289. 10:06 myoffice12: i have been trying to create a "true" "BETTER VOLUME INDICATOR" and have zero luck. does anyone here have an idea of what to do?
  290. 10:07 Mackenzie: Shizznet, thank you, but your code plots vertical lines, I don't need them, I would like to color ES red when YM is down and color ES green when YM is green.
  291. 10:07 harndog3: fas... ask support and request a plaform tour
  292. 10:08 Mackenzie: In other words, I would like ES to be painted (the candles) based on YM's movement, no vertical lines.
  293. 10:10 harndog3: myoffice... lose the color and define what you mean by better volume.
  294. 10:12 Nube: assignpricecolor( if open("/YM") close("/YM") then color.downtick else color.uptick);
  295. 10:13 myoffice12: better volume anyone?
  296. 10:13 harndog3: My ...did you try Google?
  297. 10:14 Nube: What would make the volume indicator better?
  298. 10:14 myoffice12: i have tried googling it, torrenting it, writing it, i found ninja trader has code but not the some language. im at a real loss
  299. 10:15 harndog3: That's what myoffice is asking you to define
  300. 10:15 myoffice12: better is a miss used term in this case. its called BETTER VOLUME
  301. 10:15 myoffice12: ill send a link
  302. 10:15 Nube: What's better about it?
  303. 10:15 Mackenzie: Nube: Thank you, but it says "invalid statement"
  304. 10:16 Nube: ¯\_(ツ)_/¯
  305. 10:16 Mackenzie: Nube: I got it, it was missing ">"
  306. 10:16 myoffice12: may have to get skip around
  307. 10:17 Nube: it's not supposed to have > at all, Mac?
  308. 10:17 Shizznet: Try this Mackenzie:
  309. input ColorYMColor = YES;
  310. def Up = Close("/YM")>Open("/YM");
  311. def Dn = Close("/YM")<Open("/YM");
  312. assignPriceColor( if ColorYMColor and Up then Color.UPTICK else if ColorYMColor and Dn then Color.DOWNTICK else Color.CURRENT);
  313.  
  314. 10:18 Nube: no outside links, office. House rules, not mine.
  315. 10:18 Mackenzie: Nube: It is not? Without it, it gives me an error
  316. 10:18 Nube: it should have
  317. 10:18 Shizznet: Mackenzie, I was working on something Dilbert was working on called PREM and I came up with something regarding up/down YM move. Give me a sec and I can find the study.
  318. 10:18 Shizznet: Nube, you posted too quick. Look up and you'll see there's no operator.
  319. 10:19 Shizznet: Mackenzie, let me know if the post at xx:17 works for you or not.
  320. 10:19 myoffice12: youtube: The Real Secret to Great Volume Analysis - Relative Volume
  321. 10:20 Mackenzie: Shizznet: Would be interesting to see Dilbert's stuff...yes, trying right now, will let you know
  322. 10:20 Nube: on mobile, it shows on here, but I have the wrong one so Mac is correct. I'm wrong
  323. 10:22 Mackenzie: Shizznet: It seems to work. Nube, Shizznet: Thank you very much!
  324. 10:22 Shizznet: On mobile, your comment at xx:12 cuts off after open("/YM")...
  325. 10:23 myoffice12: i really think the Better Volume indicator is something very useful. what wouldnt thinkorswim have it already?
  326. 10:23 harndog3: Myoffice, I am going to exclude you. This the TOS platform and the person selling the idea is talking about different platforms
  327. 10:23 Shizznet: Yw Mac.
  328. 10:24 Nube: That's where the operator is. It seems the mobile app struggles there and will drop everything from there on sometimes.
  329. 10:24 Nube: it's not useful, my office, that's why nobody else has it.
  330. 10:25 Mackenzie: Zhizznet: Post the Dilbert's code anyway please. I would like to try it, if that is ok.
  331. 10:25 Shizznet: Working on it Mac. Collecting garbage so platform runs a little faster then I’ll post.
  332. 10:26 myoffice12: so, no help here?
  333. 10:26 harndog: Myoffice: Here is a better volume script from Mobius: http://tos.mx/oz3r89# . Please go away
  334. 10:27 harndog: If that script works for you, you owe Mobius...
  335. 10:28 Shizznet: lol hd
  336. 10:29 Shizznet: Mackenzie, try this
  337. ### Mobius: jcseattle - Simplified code
  338. #StudyName: YMPremPlot based on Dilbert_PremPlot_V1
  339. #Description: Use to watch the difference between /YM and /ES. Rising PREM values usually lead to resistance, and visa versa.
  340. #Author: Dilbert
  341. #Requested By:
  342. # Ver Date Auth Change
  343. # V1 123016 Dilbert 1st code cut
  344. # V2 091717 jcseattle Changed symbols to just /YM and /ES
  345. # TOS.mx Link: http://tos.mx/o80rCj#
  346. # Trading Notes: Use to watch the difference between /YM and /ES. Rising PREM values usually lead to resistance, and visa versa.
  347.  
  348. input Symbol1 = "/YM";
  349. input Symbol2 = "/ES";
  350. input ShowLines = Yes;
  351. input ShowVerticalLines = Yes;
  352.  
  353. def SPXC = close(Symbol2);
  354. def YM = Close(Symbol1);
  355. def PREM = YM - SPXC;
  356. def S = if PREM crosses above Highest(PREM[1], 100)
  357. then Highest(high, 3)
  358. else S[1];
  359. plot S_line = S;
  360. def S2 = if PREM crosses below Lowest(PREM[1], 100)
  361. then lowest(low, 3)
  362. else S2[1];
  363. plot S2_line = S2;
  364. addVerticalLine(ShowVerticalLines and S != S_Line[1], "Possible Top", Color.MAGENTA, stroke = Curve.LONG_DASH);
  365. addVerticalLine(ShowVerticalLines and S2 != S2_line[1], "Possible Bottom", Color.CYAN, stroke = Curve.LONG_DASH);
  366. #End Code
  367. 10:29 mark6061: myoffice, have you called support and gotten the tour? if so call back and ask theme for their link of scripts. they may have what you are looking. people here are not tos employees.
  368. 10:29 Shizznet: You can either copy and paste the whole script or just click on the link to open it up.
  369. 10:30 AlphaInvestor: I think Dilbert gave up on that code after testing it and finding no edge
  370. 10:30 Mackenzie: Shizznet: Thank you, I appreciate it.
  371. 10:31 Shizznet:
  372. 10:32 Mackenzie: What does Churn mean in that volume script?
  373. 10:32 Shizznet: Pay attention to one thing.
  374. 10:33 Shizznet: lol
  375. 10:33 Mackenzie: Shizznet: An edge might be if you ue it on RTY vs. ZN
  376. 10:33 Mackenzie: use not ue, sorry
  377. 10:34 Shizznet: You can change the inputs if you want through the GUI that way you don't have to mess with the code.
  378. 10:34 Shizznet: Just change YM ES to RTY ZN
  379. 10:35 Shizznet: Or whatever two symbols your heart desires.
  380. 10:35 Mackenzie: Yes, I was just commenting on what you said why he gave up on it.
  381. 10:36 Shizznet: I might try the Nube indicator study on this study. lol
  382. 10:36 Mackenzie: What is the Nube indicator study?
  383. 10:36 myoffice12: lol
  384. 10:38 myoffice12: i am sorry to bother you guys. when i called tos trade desk they told me about this chat. i already emailed them to request help with the script. when i get it right i will be sharing to every one.
  385. 10:38 Mobius: MyOffice & Mack... There are extensive notes on that study "Better Volume Indicator" if you google it. The one harndog posted is written according to the originator. Some of the notes are in the header of the study
  386. 10:39 Shizznet: Didn't you say some pro traded with it to no avail, Mob?
  387. 10:41 Mobius: It's not of much use Shizz.. Too much volume is hidden now and late to the consolidated tape for intraday volume studies to be of any use
  388. 10:42 Mobius: Daily and up volume is still valid
  389. 10:42 Shizznet: I figured. Thanks.
  390. 10:43 harndog: Value is selling hope on a subscription basis
  391. 10:43 Shizznet: Repost:
  392. # Simple Chop Reduction
  393. # Nube 1.10.18
  394.  
  395. input Price = close;
  396.  
  397. def indicator = MACD().Diff; # -- Your oscillator here
  398.  
  399. def UpPrice = if indicator crosses above 0
  400. then price
  401. else UpPrice[1];
  402. def DnPrice = if indicator crosses below 0
  403. then price
  404. else DnPrice[1];
  405.  
  406. def Trend = if UpPrice crosses above UpPrice[1]
  407. then 1
  408. else if DnPrice crosses below DnPrice[1]
  409. then -1
  410. else Trend[1];
  411.  
  412. def Up = if Trend crosses above 0 then 0 else Double.NaN;
  413. Up.SetPaintingStrategy(PaintingStrategy.Arrow_Up);
  414. Up.SetDefaultColor(Color.Cyan);
  415.  
  416. def Down = if Trend crosses below 0 then 0 else Double.NaN;
  417. Down.SetPaintingStrategy(PaintingStrategy.Arrow_Down);
  418. Down.SetDefaultColor(Color.Orange);
  419. 10:43 Mackenzie: Mobius: Thank you.
  420. 10:43 Mobius: lol Nice harndog
  421. 10:43 RayK: Hi. My buffer is missing from 10:36 to 12:17 EDT today. Can someone please PB it to me? Thanks in advance!
  422. 10:44 Mobius: yw Mack...
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement