TA-Lib : Technical Analysis Library

Timeseries.AddVariable Method 

Build a new named variable from an existing array of double. The first entry in the array is assumed aligned with the first timestamps that was used to build this timeseries.

[Visual Basic]
Public Function AddVariable( _ 
   ByVal variableName As String, _ 
   ByVal data As Double() _ 
) As Variable
[C#]
public Variable AddVariable(
   string variableName,
   double[] data
);
[C++]
public: Variable* AddVariable(
   String* variableName,
   double data __gc[]
);
[JScript]
public function AddVariable(
   String variableName,
   double[] data
): Variable;

Parameters

variableName
Name of the new variable. If the variable already exist in the Timeseries, it will be replaced.
data
Floating-point values used to build the variable.

Return Value

The newly added variable.

See Also

Timeseries Class | TA.Lib Namespace