OPEN-SOURCE SCRIPT
내 스크립트

//version=5
indicator("W Pattern (Double Bottom) Alert", overlay=true)
// Pivot 설정
leftBars = 3
rightBars = 3
// 피벗 로우(저점) 두 개 탐지
pLow1 = ta.pivotlow(low, leftBars, rightBars)
pLow2 = ta.pivotlow(low, leftBars, rightBars)
// 두 번째 저점이 최근 형성되었는지
secondBottom = not na(pLow2)
// W 패턴 조건
// 1) 첫 번째 저점 존재
// 2) 두 번째 저점 존재
// 3) 두 저점 사이의 고점이 존재(넥라인)
neckline = ta.highest(high, leftBars * 4)
// 두 저점 간 가격 간격 조건 (너무 벌어지면 안됨)
validSpacing = pLow2 - pLow1 < pLow1 * 0.1
// 최종 W 패턴 조건
Wpattern = secondBottom and validSpacing and close > neckline
// 차트 표시
plotshape(secondBottom, title="Second Bottom", color=color.orange, style=shape.triangleup, size=size.tiny)
plot(neckline, "Neckline", color=color.yellow)
// 알림 트리거
alertcondition(Wpattern, title="W Pattern Detected", message="W 패턴(더블 바텀) 발생!")
indicator("W Pattern (Double Bottom) Alert", overlay=true)
// Pivot 설정
leftBars = 3
rightBars = 3
// 피벗 로우(저점) 두 개 탐지
pLow1 = ta.pivotlow(low, leftBars, rightBars)
pLow2 = ta.pivotlow(low, leftBars, rightBars)
// 두 번째 저점이 최근 형성되었는지
secondBottom = not na(pLow2)
// W 패턴 조건
// 1) 첫 번째 저점 존재
// 2) 두 번째 저점 존재
// 3) 두 저점 사이의 고점이 존재(넥라인)
neckline = ta.highest(high, leftBars * 4)
// 두 저점 간 가격 간격 조건 (너무 벌어지면 안됨)
validSpacing = pLow2 - pLow1 < pLow1 * 0.1
// 최종 W 패턴 조건
Wpattern = secondBottom and validSpacing and close > neckline
// 차트 표시
plotshape(secondBottom, title="Second Bottom", color=color.orange, style=shape.triangleup, size=size.tiny)
plot(neckline, "Neckline", color=color.yellow)
// 알림 트리거
alertcondition(Wpattern, title="W Pattern Detected", message="W 패턴(더블 바텀) 발생!")
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.
Skrip open-source
Dengan semangat TradingView yang sesungguhnya, pembuat skrip ini telah menjadikannya sebagai sumber terbuka, sehingga para trader dapat meninjau dan memverifikasi fungsinya. Salut untuk penulisnya! Meskipun Anda dapat menggunakannya secara gratis, perlu diingat bahwa penerbitan ulang kode ini tunduk pada Tata Tertib kami.
Pernyataan Penyangkalan
Informasi dan publikasi ini tidak dimaksudkan, dan bukan merupakan, saran atau rekomendasi keuangan, investasi, trading, atau jenis lainnya yang diberikan atau didukung oleh TradingView. Baca selengkapnya di Ketentuan Penggunaan.