iForce Indicator

Calculates the Force Index indicator and returns its value.

Function Signature

double iForce(
  string      symbol,       // Symbol name
  int         timeframe,    // Timeframe
  int         period,       // Averaging period
  int         ma_method,    // Averaging method
  int         applied_price, // Applied price
  int         shift         // Shift
);

Parameters

  • **symbol**: string - Symbol name. NULL indicates the current symbol.
  • **timeframe**: int - Timeframe. Use ENUM_TIMEFRAMES values. 0 indicates the current chart timeframe.
  • **period**: int - Averaging period for calculation.
  • **ma_method**: int - Moving Average method. Use ENUM_MA_METHOD values.
  • **applied_price**: int - Applied price. Use ENUM_APPLIED_PRICE values.
  • **shift**: int - Index of the value taken from the indicator buffer (shift relative to the current bar).
  • Return Value

  • double - Numerical value of the Force Index indicator.
  • Example

    double val = iForce(NULL, 0, 13, MODE_SMA, PRICE_CLOSE, 0);
    

    Related Indicators

  • [iEnvelopesOnArray](/indicators/ienvelopesonarray)
  • [iFractals](/indicators/ifractals)
  • Platform Support

  • MQL4 Language
  • MetaTrader 4 Platform
  • Constants Used

  • ENUM_TIMEFRAMES
  • ENUM_MA_METHOD
  • ENUM_APPLIED_PRICE
  • Navigation

  • [MQL4 Reference](/)
  • [Technical Indicators](/indicators)
  • [iAC](/indicators/iac)
  • [iAD](/indicators/iad)
  • ... (List of all indicators omitted for brevity in this version, but available in full documentation)
  • Downloads

  • [MQL4 Help (English)](https://www.mql5.com/files/docs/mql4.chm)
  • [MQL4 Help (Russian)](https://www.mql5.com/files/docs/mql4_russian.chm)
  • MetaTrader 5 Downloads

  • [Windows](https://download.mql5.com/cdn/web/metaquotes.ltd/mt5/mt5setup.exe)
  • [iPhone/iPad](https://download.mql5.com/cdn/mobile/mt5/ios)
  • [Mac OS](https://download.mql5.com/cdn/web/metaquotes.software.corp/mt5/MetaTrader5.dmg)
  • [Android](https://download.mql5.com/cdn/mobile/mt5/android)
  • [Huawei](https://download.mql5.com/cdn/mobile/mt5/android/app-gallery)
  • [Linux](https://www.mql5.com/en/articles/625)
  • Legal & Policy

  • [Terms and Conditions](https://www.mql4.com/about/terms)
  • [Privacy and Data Protection Policy](https://www.mql5.com/en/about/privacy)
  • [Cookies Policy](https://www.mql5.com/en/about/cookies)