New version 17 available now


Download software Tutorial videos
Subscription & data-feed pricing Class schedule


New account application Trading resources
Margin rates Stock & option commissions

Welcome Guest, please sign in to participate in a discussion. Search | Active Topics |

Profile: maljester
About
User Name: maljester
Groups: Gold User, Member, Platinum User, TeleChart
Rank: Registered User
Real Name:
Location
Occupation:
Interests:
Gender: Unsure
Statistics
Joined: Sunday, January 30, 2005
Last Visit: Friday, October 13, 2017 5:39:36 PM
Number of Posts: 113
[0.04% of all post / 0.02 posts per day]
Avatar
Last 10 Posts
Topic: Weis Wave
Posted: Sunday, September 17, 2017 7:15:19 PM

This is an old topic but I would like to address it again.

I converted the following to RealCode 

// @author LazyBear 
// List of all my indicators: https://www.tradingview.com/v/4IneGo8h/
//
study("Weis Wave Volume [LazyBear]", shorttitle="WWV_LB")
trendDetectionLength=input(2)
showDistributionBelowZero=input(false, type=bool)
mov = close>close[1] ? 1 : close<close[1] ? -1 : 0
trend= (mov != 0) and (mov != mov[1]) ? mov : nz(trend[1])
isTrending = rising(close, trendDetectionLength) or falling(close, trendDetectionLength) //abs(close-close[1]) >= dif
wave=(trend != nz(wave[1])) and isTrending ? trend : nz(wave[1])
vol=wave==wave[1] ? (nz(vol[1])+volume) : volume
up=wave == 1 ? vol : 0
dn=showDistributionBelowZero ? (wave == 1 ? 0 : wave == -1 ? -vol : vol) : (wave == 1 ? 0 : vol)
plot(up, style=histogram, color=green, linewidth=3)
plot(dn, style=histogram, color=red, linewidth=3)
 
My RealCode
&#39;# TrendLength = UserInput.Integer = 2
Static mov As Single
Static prevmov As Single
Static trend As Single
Static prevtrend As Single
Static isTrending As Single
Static wave As Single
Static prevwave As Single
Static vol As Single
 
If isFirstBar Then
     mov = 0
     prevmov = 0
     trend = 0
     prevtrend = 0
     isTrending = 0
     wave = 0
     prevwave = 0
     vol = 0
End If
&#39;mov = close>close[1] ? 1 : close<close[1] ? -1 : 0
If price.close > price.Close(1) Then
     mov = 1
Else If price.close < price.close(1) Then
     mov = -1
Else
     mov = 0
End If
&#39;trend= (mov != 0) and (mov != mov[1]) ? mov : nz(trend[1])
If mov <> 0 And mov <> prevmov Then
     trend = mov
Else
     trend = prevtrend
End If
&#39;isTrending = rising(close, trendDetectionLength) or falling(close, trendDetectionLength)
If price.close > price.close(1) AndAlso price.Close(1) > price.Close(2) _
     Or price.close < price.Close(1) AndAlso price.close(1) < price.Close(2) Then
     isTrending = 1
Else
     isTrending = 0
End If
&#39;wave = (trend != nz(wave[1])) and isTrending ? trend : nz(wave[1])
If trend <> prevwave AndAlso isTrending = 1 Then
     wave = trend
Else
     wave = prevwave
End If
&#39;vol = wave==wave[1] ? (nz(vol[1])+volume) : volume
If wave = prevwave Then
     vol += volume.value
Else
     vol = volume.value
End If
If wave = 1 Then
     plot = vol
Else
     plot = -vol
End If
prevmov = mov
prevtrend = trend
prevwave = wave
 
This version has down volume displayed below 0, because I did not know how to set 2 different plot colors in the indicator RealCode.  I set the plot to Bar in the edit window for the indicator and the Paint Scheme in the edit window.  I like how this version matches to price movement.
 
My question - is this version of Weis Wave possible in TC2000 V17?
 

  

Topic: StochRSI for StockFinder
Posted: Saturday, March 04, 2017 9:32:20 AM

The file you attached works great.  Thanks for your help.

Topic: StochRSI for StockFinder
Posted: Thursday, March 02, 2017 3:26:57 PM

The StockFinder builtin Stochastic RSI does not match TC2000 V17 version.  It does not have same parameters as TC2000.

Is RealCode possible for RSI of 5, Stochastic of 9, %K of 3?

Topic: ConnorsRSI
Posted: Wednesday, February 22, 2017 1:47:37 PM

Matches SF.  Thanks for your help. Worden is very lucky to have you.

Topic: ConnorsRSI
Posted: Wednesday, February 22, 2017 9:26:17 AM

Bruce, the TC2000 code you posted for Connors RSI on 1/26/2017 does not give results that match the code you did for StockFinder.  I believe the SF code is accurate.  Example SF has 77.55, TC has 66.55 for symbol SQ as of 2/21/2017.

Topic: Diceman TTM for SF
Posted: Monday, February 13, 2017 4:23:02 PM

Works great.  Matches TC and TOS.

Thanks for your help

Topic: Diceman TTM for SF
Posted: Monday, February 13, 2017 3:01:54 PM

I translated Diceman TTM momentum to SF as follows.  Does not seem to match TC2000 V17.

Do I have an error?

plot = price.AVGC(20) - ((price.MovingAverage(20).MAXHigh(20) _
+ price.MovingAverage(20).MINLow(20)) / 2 _
+ price.ExponentialAverage(20).AVGC(20)) / 2 _
+ 9.5 * (9.5 * (price.CLOSE - ((price.MAXHIGH(20) + price.MINLOW(20)) / 2 + price.XAVGC(20)) / 2) _
+ 8.5 * (price.Close(1) - ((price.MAXHigh(20, 1) + price.MINLow(20, 1)) / 2 + price.XAVGC(20, 1)) / 2) _
+ 7.5 * (price.Close(2) - ((price.MAXHigh(20, 2) + price.MINLow(20, 2)) / 2 + price.XAVGC(20, 2)) / 2) _
+ 6.5 * (price.Close(3) - ((price.MAXHigh(20, 3) + price.MINLow(20, 3)) / 2 + price.XAVGC(20, 3)) / 2) _
+ 5.5 * (price.Close(4) - ((price.MAXHigh(20, 4) + price.MINLow(20, 4)) / 2 + price.XAVGC(20, 4)) / 2) _
+ 4.5 * (price.Close(5) - ((price.MAXHigh(20, 5) + price.MINLow(20, 5)) / 2 + price.XAVGC(20, 5)) / 2) _
+ 3.5 * (price.Close(6) - ((price.MAXHigh(20, 6) + price.MINLow(20, 6)) / 2 + price.XAVGC(20, 6)) / 2) _
+ 2.5 * (price.Close(7) - ((price.MAXHigh(20, 7) + price.MINLow(20, 7)) / 2 + price.XAVGC(20, 7)) / 2) _
+ 1.5 * (price.Close(8) - ((price.MAXHigh(20, 8) + price.MINLow(20, 8)) / 2 + price.XAVGC(20, 8)) / 2) _
+ .5 * (price.Close(9) - ((price.MAXHigh(20, 9) + price.MINLow(20, 9)) / 2 + price.XAVGC(20, 9)) / 2) _
- .5 * (price.Close(10) - ((price.MAXHigh(20, 10) + price.MINLow(20, 10)) / 2 + price.XAVGC(20, 10)) / 2) _
- 1.5 * (price.Close(11) - ((price.MAXHigh(20, 11) + price.MINLow(20, 11)) / 2 + price.XAVGC(20, 11)) / 2) _
- 2.5 * (price.Close(12) - ((price.MAXHigh(20, 12) + price.MINLow(20, 12)) / 2 + price.XAVGC(20, 12)) / 2) _
- 3.5 * (price.Close(13) - ((price.MAXHigh(20, 13) + price.MINLow(20, 13)) / 2 + price.XAVGC(20, 13)) / 2) _
- 4.5 * (price.Close(14) - ((price.MAXHigh(20, 14) + price.MINLow(20, 14)) / 2 + price.XAVGC(20, 14)) / 2) _
- 5.5 * (price.Close(15) - ((price.MAXHigh(20, 15) + price.MINLow(20, 15)) / 2 + price.XAVGC(20, 15)) / 2) _
- 6.5 * (price.Close(16) - ((price.MAXHigh(20, 16) + price.MINLow(20, 16)) / 2 + price.XAVGC(20, 16)) / 2) _
- 7.5 * (price.Close(17) - ((price.MAXHigh(20, 17) + price.MINLow(20, 17)) / 2 + price.XAVGC(20, 17)) / 2) _
- 8.5 * (price.Close(18) - ((price.MAXHigh(20, 18) + price.MINLow(20, 18)) / 2 + price.XAVGC(20, 18)) / 2) _
- 9.5 * (price.Close(19) - ((price.MAXHigh(20, 19) + price.MINLow(20, 19)) / 2 + price.XAVGC(20, 19)) / 2) ) / 665
Topic: Inverse Fisher Transform
Posted: Thursday, January 19, 2017 8:07:33 AM

Thanks for your help.   WRSI give better results.

Topic: Inverse Fisher Transform
Posted: Wednesday, January 18, 2017 2:33:04 PM

Two questions.

1. Does V17 now permit a pcf for Inverse Fisher Transform for the Following MetaStock code?

v1:=.1*(RSI(5) - 50);
v2:=Mov(v1, 9, W);
(Exp(2 * v2) - 1)/(Exp(2 * v2) + 1)

2.  I have done the following in SF to get a IFT

V1 is plot = .1 * (Price.RSI(5, 1) - 50)

V2 is created with overlay child inddicator of V1 that is front weighted 9 period average.

Drag V2 into a 3rd RealCode indicator to create final IFT

&#39;# V2 = chart.MovingAverage.7
 
plot = (math.Exp(2 * v2.close) - 1) / (math.Exp(2 * v2.close) + 1)
 
Can my 3 steps for SF be done in one RealCode indicator?
Topic: VLTC not in SF5
Posted: Tuesday, January 03, 2017 3:17:34 PM

Stock was also delisted from NASDAQ on Dec 23, 2016