ค้นหา
ผลิตภัณฑ์
ชุมชน
ตลาด
ข่าว
โบรกเกอร์
เพิ่มเติม
TH
เริ่มกันเลย
ทองคำ / ดอลลาร์สหรัฐ
7 ก.พ. 2024
Ok
0
เลือกชาร์ตนี้
เลือกชาร์ตนี้
//
version
=5
indicator("Simple SMA Crossover", overlay=true)
// Define the lengths for the short and long simple moving averages
shortLength = input(9, title="Short SMA Length")
longLength = input(21, title="Long SMA Length")
// Calculate the SMAs
shortSMA = ta.sma(close, shortLength)
longSMA = ta.sma(close, longLength)
// Plot the SMAs on the chart
plot(shortSMA, title="Short SMA", color=color.red)
plot(longSMA, title="Long SMA", color=color.blue)
// Generate buy and sell signals
buySignal = ta.crossover(shortSMA, longSMA)
sellSignal = ta.crossunder(shortSMA, longSMA)
// Plot buy and sell signals
plotshape(series=buySignal, title="Buy Signal", location=location.belowbar, color=color.green, style=shape.labelup, text="BUY")
plotshape(series=sellSignal, title="Sell Signal", location=location.abovebar, color=color.red, style=shape.labeldown, text="SELL")
shelby_petroleum
ติดตาม
Trend Analysis
shelby_petroleum
ติดตาม
คำจำกัดสิทธิ์ความรับผิดชอบ
ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่
ข้อกำหนดการใช้งาน