IMsTimeMatrix.CurrentIndex

Syntax

CurrentIndex: Integer;

Description

The CurrentIndex property returns the current calculation index.

Comments

To get series start index, use the IMsTimeMatrix.StartIndex property.

Example

This example describes custom method.

To execute the example, add links to the Ms, Dimensions, MathFin system assemblies.

Public Function CalendarLevel(param: IMsTimeMatrix): Variant;
Var 
    Serie : ITimeSeries;
    index, i: integer;
    arr: Array Of Double;
Begin
    Serie := New TimeSeries.Create;
    index := param.CurrentIndex;
    If param.CalendarLevel = DimCalendarLevel.Year Then
        For i := 0 To param.PointCount - 1 Do
            arr := param.Column(i) As Array Of double;
            Serie.Item(index) := Math.Max(arr);
        End For;
    End If;
    Return Serie;
End Function CalendarLevel;

The method finds maximum values in matrix series points if matrix series contains annual calendar frequency.

See also:

IMsTimeMatrix