거래 로봇을 무료로 다운로드 하는 법을 시청해보세요
당사를 Telegram에서 찾아주십시오!
당사 팬 페이지에 가입하십시오
스크립트가 흥미로우신가요?
그렇다면 링크 to it -
하셔서 다른 이들이 평가할 수 있도록 해보세요
스크립트가 마음에 드시나요? MetaTrader 5 터미널에서 시도해보십시오
라이브러리

Statistical Functions - MetaTrader 5용 라이브러리

조회수:
8893
평가:
(49)
게시됨:
2015.05.27 17:09
업데이트됨:
2016.11.22 07:32
이 코드를 기반으로 한 로봇이나 지표가 필요하신가요? 프리랜스로 주문하세요 프리랜스로 이동

Set of statistical functions which allows you to calculate some values describing timeseries like correlation between two time series, linear regression, standard deviation etc. It includes also more advanced functions like definite integral.

Header file "Statistics.mqh" includes following functions:

Syntax Description Return type
 mean(T &arr[])  Mean  (generic) 
 std(double &arr[])  Standard deviation  double
 correlation(&arr1[], &arr2[])  Correlation coefficient  double
 detrend(arr[], resultArray[])  Timeseries decomposition  void
 regression(&arr1[], &arr2[], &res[])  Regression line  void
 regression(double &arr1[], double &arr2[], double &res[], double &aCoeff,double &bCoeff)  Regression line with coefficients  void
 dickeyFuller(double &arr[])   Dickey-Fuller test for stationarity  bool
 engleGrangerTest(double &arr1[], double &arr2[],double &cointCoeff)   Engle-Granger 2-step method for testing cointegration  bool
 AR1(double &arr[])  Autoregressive model with lag 1  double
 signedIntegral(double a, double b, int n) *  Definite integral  double
 erf(double x)   Error function  double
 normDistZ(double z)   Probability that variable is from normal distrbution  double

* You should add your own implementation of "foo" function which you want to integrate. Default function is: f(x) = x.

You should also remember that timeseries avaliable in MQL are indexed in a way that the newest data have a 0 index. It's a good idea to reverse the order of such arrays and is absolutely necessay in AR model (arrays are not reversed inside of the method to avoid confusion).

BinaryWaveSign BinaryWaveSign

Semaphore signal indicator triggering when the BinaryWave indicator changes direction.

StochasticTrend_x10 StochasticTrend_x10

The StochasticTrend_x10 indicator shows the Stochastic oscillator position from ten different timeframes.

Currency Correlation II Currency Correlation II

The indicator shows correlation between currencies.

StocksBG StocksBG

StocksBG indicator displays the activity of major stock exchanges on a chart with M15 or less timeframe.