HPotter

Force Index

Hi,
This Indicator plots the Force Index as described by Dr. Alexander
Elder in "Trading For a Living." The ForceIndex indicator relates
price to volume by multiplying net change and volume. ForceIndex is
calculated using the following equation:
ForceIndex = Volume(today) * (Close(this period) - Close(last period))
ForceIndex is typically presented as two smoothed averages (slow and fast)
to avoid false signals.

สคริปต์โอเพนซอร์ซ

ด้วยจิตวิญญาณของ TradingView อย่างแท้จริง ผู้เขียนสคริปต์นี้ได้เผยแพร่เป็นโอเพนซอร์ส เพื่อให้ผู้ค้าสามารถเข้าใจและตรวจสอบได้ ไชโยให้กับผู้เขียน! คุณสามารถใช้ได้ฟรี แต่การใช้รหัสนี้ซ้ำในสิ่งพิมพ์อยู่ภายใต้กฎระเบียบการใช้งาน คุณสามารถตั้งเป็นรายการโปรดเพื่อใช้บนชาร์ตได้

คำจำกัดสิทธิ์ความรับผิดชอบ

ข้อมูลและบทความไม่ได้มีวัตถุประสงค์เพื่อก่อให้เกิดกิจกรรมทางการเงิน, การลงทุน, การซื้อขาย, ข้อเสนอแนะ หรือคำแนะนำประเภทอื่น ๆ ที่ให้หรือรับรองโดย TradingView อ่านเพิ่มเติมที่ เงื่อนไขการใช้บริการ

ต้องการที่จะใช้สคริปต์นี้บนชาร์ตใช่ไหม?
////////////////////////////////////////////////////////////
//  Copyright by HPotter v1.0 28/04/2014
// This Indicator plots the Force Index as described by Dr. Alexander 
// Elder in "Trading For a Living." The ForceIndex indicator relates 
// price to volume by multiplying net change and volume. ForceIndex is 
// calculated using the following equation:
// ForceIndex = Volume(today) * (Close(this period) - Close(last period))
// ForceIndex is typically presented as two smoothed averages (slow and fast) 
// to avoid false signals. 
////////////////////////////////////////////////////////////
study(title="Force Index", shorttitle="Force Index")
XLen1 = input(3, minval=1)
XLen2 = input(13, minval=1)
hline(0, color=green, linestyle=line)
xValue = volume * (close - close[1])
xSMA1 = ema(xValue, XLen1)
xSMA2 = ema(xValue, XLen2)
plot(xSMA1, style = histogram, color=blue, title="SlowAvg")
plot(xSMA2, color=red, title="FastAvg")