Class VariableArray<T>
One-dimensional flat variable array.
Inheritance
Variable<T[]>
VariableArrayBase<Variable<T>, T[]>
VariableArray<Variable<T>, T[]>
VariableArray<T>
Inherited Members
Namespace: Microsoft.ML.Probabilistic.Models
Assembly: Microsoft.ML.Probabilistic.Compiler.dll
Syntax
public class VariableArray<T> : VariableArray<Variable<T>, T[]>, CanGetContainers, IModelExpression<T[]>, SettableTo<Variable<T[]>>, ICloneable, HasItemVariables, IVariableJaggedArray, SettableTo<VariableArray<Variable<T>, T[]>>, IVariableArray<T>, IJaggedVariableArray<Variable<T>>, SettableTo<VariableArray<T>>, IVariableArray, IVariable, IModelExpression, HasObservedValue
Type Parameters
Name | Description |
---|---|
T |
Constructors
VariableArray(VariableArray<T>)
Copy constructor.
Declaration
protected VariableArray(VariableArray<T> that)
Parameters
Type | Name | Description |
---|---|---|
VariableArray<T> | that |
Methods
Attrib(ICompilerAttribute)
Inline method for adding an attribute to a random variable. This method returns the random variable object, so that is can be used in an inline expression. e.g. Variable.GaussianFromMeanAndVariance(0,1).Attrib(new MyAttribute());
Declaration
public VariableArray<T> Attrib(ICompilerAttribute attr)
Parameters
Type | Name | Description |
---|---|---|
ICompilerAttribute | attr | The attribute to add |
Returns
Type | Description |
---|---|
VariableArray<T> | The random variable object |
Attrib(QueryType)
Helper to add a query type attribute to this variable.
Declaration
public VariableArray<T> Attrib(QueryType queryType)
Parameters
Type | Name | Description |
---|---|---|
QueryType | queryType | The query type to use to create the attribute |
Returns
Type | Description |
---|---|
VariableArray<T> |
Clone()
Clone the array
Declaration
public override object Clone()
Returns
Type | Description |
---|---|
Object |
Overrides
Microsoft.ML.Probabilistic.Models.VariableArray<Microsoft.ML.Probabilistic.Models.Variable<T>, T[]>.Clone()
Named(String)
Set the name of the array.
Declaration
public VariableArray<T> Named(string name)
Parameters
Type | Name | Description |
---|---|---|
String | name |
Returns
Type | Description |
---|---|
VariableArray<T> |
|
SetTo(VariableArray<T>)
Set the 1-D array to the given value
Declaration
public void SetTo(VariableArray<T> that)
Parameters
Type | Name | Description |
---|---|---|
VariableArray<T> | that |
Explicit Interface Implementations
IVariableArray.ReplaceRanges(Dictionary<Range, Range>, Dictionary<IModelExpression, IModelExpression>, Boolean)
Declaration
IVariableArray IVariableArray.ReplaceRanges(Dictionary<Range, Range> rangeReplacements, Dictionary<IModelExpression, IModelExpression> expressionReplacements, bool deepCopy)
Parameters
Type | Name | Description |
---|---|---|
Dictionary<Range, Range> | rangeReplacements | |
Dictionary<IModelExpression, IModelExpression> | expressionReplacements | |
Boolean | deepCopy |
Returns
Type | Description |
---|---|
IVariableArray |