summaryrefslogtreecommitdiff
path: root/macros/diffpara.sci
diff options
context:
space:
mode:
Diffstat (limited to 'macros/diffpara.sci')
-rw-r--r--macros/diffpara.sci17
1 files changed, 17 insertions, 0 deletions
diff --git a/macros/diffpara.sci b/macros/diffpara.sci
index 3f9e2d9..c36ae7c 100644
--- a/macros/diffpara.sci
+++ b/macros/diffpara.sci
@@ -1,4 +1,21 @@
function [D,DD] = diffpara(X,varargin)
+//Return the estimator D for the differencing parameter of an integrated time series
+//Calling Sequence
+// [D, DD] = diffpara (X)
+// [D, DD] = diffpara (X, A)
+// [D, DD] = diffpara (X, A, B)
+//Parameters
+//X: Input scalar or vector.
+//DD:The estimators for all frequencies in the intervals described above.
+//D:The mean of DD
+//Description
+//Return the estimator D for the differencing parameter of an integrated time series.
+//
+//The frequencies from [2*pi*a/t, 2*pi*b/T] are used for the estimation. If B is omitted, the interval [2*pi/T, 2*pi*a/T] is used. If both B and A are omitted then a = 0.5 * sqrt (T) and b = 1.5 * sqrt (T) is used, where T is the sample size. If X is a matrix, the differencing parameter of each column is estimated.
+//
+//The estimators for all frequencies in the intervals described above is returned in DD.
+//
+//The value of D is simply the mean of DD.
lhs= argn(1);
rhs= argn(2);
if(rhs <1 | rhs> 3)