The code is incomplete, therefore not possible to see the problemby rigel - Trading Discussion
Add this parameter growColor = color.blue,by rigel - Trading Discussion
Because AddCloud expect two colors as parameters. You only have one specified, the other, red, is assigned by defaultby rigel - Trading Discussion
Try this def A = highest(close,10); def peak= if close==A then barnumber() else double.nan ; plot mylow= getvalue(low,(barnumber()-peak+1)) ; mylow.setPaintingStrategy(paintingStrategy.HORIZONTAL) ;by rigel - Trading Discussion
Hi Your question is about how to create and alert OR have to be informed by sms? Alerts in your programs can de sent to you by sms if you setup up it in the Notifications area: Youtubeby rigel - Trading Discussion
The problem is that AssignBackgroundColor changes ALL the color of the background, not just a portion as you are trying to do. What you want is to change dynamically portions of the background, you can do that using AddCloud Somewhere in this thread Robert posted a solution to that.by rigel - Trading Discussion
try something like this in your code: def cond1= if whatever then 1 else 0; def cond2= if whatever then 1 else 0; def cond3= if whatever then 1 else 0; def cond4= if whatever then 1 else 0; def cond5= if whatever then 1 else 0; def status=cond1+cond2+cond3+cond4+cond5; Def mysignal= if status >=3 then yes else no;by rigel - Trading Discussion
In a scan, this will work: def green=islongWhite(); def cond =if green and green[1] and green[2] then yes else no; plot c= if cond then close else double.nan;by rigel - Trading Discussion
You can't do it with code,I believe, due to a conflict of scales.The chart is linked to a symbol with its own scale. If you want vix overlayed, it would be necessary to have a second scale to display it.by rigel - Trading Discussion
Sara you can use a build in function Linkby rigel - Trading Discussion
The code you are posting is the rsi. If it is modified and has better divergencies as you saiy, then the code is not complete. Can you post a link? Rby rigel - Trading Discussion
Mobile That is just the rsi indicator, you don't need to program it, use the function in TOSby rigel - Trading Discussion
Mobil Can you point to the indicator you want to convert? I see in your code two problems: - you define Value, but do nothing with it. -the second part will need to be plotted as a lower indicator not in the chart.by rigel - Trading Discussion
If you post your code we can have a look togetherby rigel - Trading Discussion
You can do it using getValue(source, i) where i is a variable to iterate bar numbers. You will need to use getValue in a fold loop. For example to find the highest value: def valueA = fold i = 1 to 100 with sourcemax=0 do if getValue(source, i) >sourcemax then getValue(source, i) else sourcemax; Now for the bar number: def barnumberA = fold m= 1 to 100 do if getValue(source,mby rigel - Trading Discussion
Do you want the four values (A,B,C,D) or the "n" values that can happen in your time frame?by rigel - Trading Discussion
Quote1uni_verse I just think it may be what's behind the indicator. I'm trying to replicate what's pictured and I think the workings behind it are just two OBV's but with different settings All depends on how you want to program it. As you seem to want two OBV, one with whatever the chart TF is (5 min, 15 min, etc) and a OBV with time frame week, then you can code the couple in the same indby rigel - Trading Discussion
Coding for TOS from Francesco original # #From Prorealcode to TOS by Rigel # declare lower; #//input parameters input TCLen = 10; input MA1 = 23; input MA2 = 50; def Factor= 0.5; # //{Calculate a MACD Line} def XMAC = ExpAverage(Close,MA1) - ExpAverage(Close,MA2); # //{1st Stochastic: Calculate Stochastic of a MACD} def Value1 = Lowest(XMAC,TCLen); def Value2by rigel - Trading Discussion
Hi I have shown some examples coding multi-ttime frames in an indicator. Please search my post. Rgds Rby rigel - Trading Discussion
netarchitect If I un-comment your lines what I got in the scan is : com.devexperts.tos.thinkscript.runtime.TooComplexException: The complexity of the expression suggests that it may not be reliable with real-time data. So, it doesn't allow to save the script. Scan are know for not accepting (working well ) with complex studies.by rigel - Trading Discussion
Can you post a link to such cumulative values?by rigel - Trading Discussion
Fredm try this at the end of your code: #-------- Alerts def conditionBull = Crosses(DPO, UpperBand, CrossingDirection.Above) ; def conditionBear = Crosses(DPO, LowerBand, CrossingDirection.Below) ; Alert(conditionBull, "Bullish!", Alert.BAR,sound.ring) ; Alert(conditionBear, "Bearish!", Alert.BAR,sound.ring) ;by rigel - Trading Discussion
TOS script language does not offer the capabilities to modify volume bar shape(width) neither candle width.by rigel - Trading Discussion
QuoteSuperspot Hi all, I am in need of a thinkscript, I want to plot the 4Hr. 5SMA on to a 5Min. Chart. Any help will be appreciated, thanks ------------------------------------------------------- Hi, please look in my replies, I am sure that somewhere I have already indicated how to combine different aggregation times Rby rigel - Trading Discussion
Paperclips I'm not totally sure what you are trying to do ... try this and will print the bubbles on top of the inside bar #Plots InsideDay Bars def lowVol = (VolatilityStdDev(6) / VolatilityStdDev(100)) < 0.5; def insideDay = high < high[1] and low > low[1]; def range = high - low; def NR4 = range < Lowest(range[1], 3); plot signal = lowVol and insideDay and NR4; #by rigel - Trading Discussion
as buy (or sell) is either yes or no, this should work AddLabel(buy,((close-open)*.25)+open ,color.lighT_GREEN); AddLabel(sell, ((open-close)*.75)+close ,color.pink); That will print the labels only when buy or sell are trueby rigel - Trading Discussion