Variable Class 
Namespace: MicrosoftResearch.Infer.Models
The Variable type exposes the following members.
Name  Description  

AddAttribute(ICompilerAttribute) 
Adds an attribute to this variable. Attributes can be used
to modify how inference is performed on this variable.
 
AddAttribute(QueryType) 
Helper to add a query type attribute to this variable.
 
AddAttributes(ICompilerAttribute) 
Adds multiple attributes to this variable.
 
AddAttributes(IEnumerableICompilerAttribute) 
Adds multiple attributes to this variable.
 
AddDefinitionAttribute 
Add an attribute to the factor defining this variable.
 
AllTrue(VariableBoolean) 
Returns a boolean variable which is true if all array elements are true.
For AND of two variables, use the & operator.
 
AllTrue(VariableIListBoolean) 
Returns a boolean variable which is true if all array elements are true.
For AND of two variables, use the & operator.
 
ArrayT(Range) 
Creates a 1D random variable array with a specified size.
 
ArrayT(IListRange) 
Creates a 1D or 2D random variable array whose dimensions are specified by a list of Range objects.
 
ArrayT(Range, Range) 
Creates a 2D random variable array with specified dimensions.
 
ArrayT(VariableArrayT, Range) 
Creates a 1D random variable array that contains a jagged array of 1D random variables.
 
ArrayT(VariableArray2DT, Range) 
Creates a 1D random variable array that contains a jagged array of 2D random variables.
 
ArrayT(Range, Range, Range) 
Creates a 3D random variable array with specified dimensions.
 
ArrayT(VariableArrayT, Range, Range) 
Creates a 2D random variable array that contains a jagged array of 1D random variables.
 
ArrayT(VariableArrayT, Range, Range, Range) 
Creates a 3D VariableArray object that contains a jagged array of 1D random variables.
 
ArrayTItem, TArray(TItem, Range) 
Create a 1D array of random variables
 
ArrayTItem, TArray(VariableArrayTItem, TArray, Range) 
Create a 1D array of 1D random variable arrays
 
ArrayFromVector 
Create a random array from values in a Vector.
 
Attrib 
Inline method for adding an attribute to a variable. This method
returns the variable object, so that is can be used in an inline expression.
e.g. Variable.GaussianFromMeanAndVariance(0,1).Attrib(new MyAttribute());
 
Bernoulli(Double) 
Creates a Boolean random variable with a specified probability of being true.
 
Bernoulli(VariableDouble) 
Creates a Boolean random variable with the probability of being true specified by a random variable.
 
BernoulliFromLogOdds(Double) 
Creates a Boolean random variable with the probability of being true specified by the input's
logistic function.
 
BernoulliFromLogOdds(VariableDouble) 
Creates a Boolean random variable with the probability of being true specified by the input's
logistic function, which is represented by a random variable.
 
BernoulliIntegerSubset(ISparseListDouble) 
Creates a random variable whose domain is a list of type integer.
 
BernoulliIntegerSubset(VariableISparseListDouble) 
Creates a random variable whose domain is a list of type integer.
 
BernoulliList(ISparseListDouble) 
Creates a random variable whose domain is a sparse list of bools.
 
BernoulliList(VariableISparseListDouble) 
Creates a random variable whose domain is a sparse list of bools.
 
Beta(Double, Double) 
Creates a Betadistributed random variable from initial success/failure counts.
 
Beta(VariableDouble, VariableDouble) 
Creates a Betadistributed random variable from initial success/failure counts that are
represented by random variables.
 
BetaFromMeanAndVariance(Double, Double) 
Creates a Betadistributed random variable with specified mean and variance
 
BetaFromMeanAndVariance(VariableDouble, VariableDouble) 
Creates a Betadistributed random variable with the mean and variance specified by random variables.
 
Binomial(Int32, VariableDouble) 
Creates a Binomiallydistributed random variable with the specified probability of success per trial and number of trials.
 
Binomial(VariableInt32, VariableDouble) 
Creates a Binomiallydistributed random variable with the specified probability of success per trial and number of trials.
 
Case 
Opens a stochastic case statement, active when the integer argument has the specified value.
 
Char 
Creates a character random variable defined by a discrete distribution induced by a given probability vector.
 
CharDigit 
Creates a character random variable from a uniform distribution over digits '0'..'9'.
 
CharLetter 
Creates a character random variable from a uniform distribution over letters in 'a'..'z' and 'A'..'Z'.
 
CharLetterOrDigit 
Creates a character random variable from a uniform distribution over 'a'..'z', 'A'..'Z' and '0'..'9'.
 
CharLower 
Creates a character random variable from a uniform distribution over lowercase letters 'a'..'z'.
 
CharNonWord 
Creates a character random variable from a uniform distribution over all characters except
('a'..'z', 'A'..'Z', '0'..'9', '_' and '\'').
 
CharUniform 
Creates a character random variable from a uniform distribution over all possible characters.
 
CharUpper 
Creates a character random variable from a uniform distribution over uppercase letters 'A'..'Z'.
 
CharWhitespace 
Creates a character random variable from a uniform distribution over whitespace characters
('\t'..'\r', ' ').
 
CharWord 
Creates a character random variable from a uniform distribution over word characters
('a'..'z', 'A'..'Z', '0'..'9', '_' and '\'').
 
CloseAllBlocks 
Close blocks in order to recover from exceptions
 
Concat 
Creates a random Vector by concatenating two random Vectors.
 
ConstantT(IListT) 
Defines a constant which is a 1D array.
 
ConstantT(T) 
Defines a constant
 
ConstantT(T) 
Defines a constant which is a 2D array.
 
ConstantT(T) 
Defines a constant which is a 1D array.
 
ConstantT(IListT, Range) 
Defines a constant which is a 1D array.
 
ConstantT(T, Range) 
Defines a constant which is a 1D array.
 
ConstantT(IListIListT, Range, Range) 
Defines a constant which is a 2D jagged array.
 
ConstantT(T, Range, Range) 
Defines a constant which is a 2D array.
 
ConstantT(T, Range, Range) 
Defines a constant which is a 2D jagged array
 
ConstantT(T, Range, Range, Range) 
Defines a constant array of 2D arrays
 
ConstantT(T, Range, Range, Range) 
Defines a constant 3D jagged array
 
ConstrainT(ConstrainMethodT, VariableT) 
Applies a constraint using a constraint method with one argument.
 
ConstrainT1, T2(ConstrainMethodT1, T2, VariableT1, VariableT2) 
Applies a constraint using a constraint method with two arguments.
 
ConstrainT1, T2, T3(ConstrainMethodT1, T2, T3, VariableT1, VariableT2, VariableT3) 
Applies a constraint using a constraint method with three arguments.
 
ConstrainT1, T2, T3, T4(ConstrainMethodT1, T2, T3, T4, VariableT1, VariableT2, VariableT3, VariableT4) 
Applies a constraint using a constraint method with four arguments.
 
ConstrainBetween 
Constrains a double variable to be between two limits.
 
ConstrainEqualT(T, VariableT) 
Constrains a variable to equal a constant value.
 
ConstrainEqualT(VariableT, VariableT) 
Constrains two variables to be equal.
 
ConstrainEqualT(VariableT, T) 
Constrains a variable to equal a constant value.
 
ConstrainEqualRandomT, TDist(T, VariableTDist) 
Constrains a value to be equal to a random sample from a distribution.
 
ConstrainEqualRandomT, TDist(VariableT, VariableTDist) 
Constrains a variable to be equal to a random sample from a distribution.
 
ConstrainEqualRandomT, TDist(VariableT, TDist) 
Constrains a variable to be equal to a random sample from a known distribution.
 
ConstrainFalse 
Constrains a boolean variable to be false.
 
ConstrainPositive 
Constrains a double variable to be positive.
 
ConstrainTrue 
Constrains a boolean variable to be true.
 
CopyT(VariableT) 
Returns a copy of the argument
 
CopyT(VariableArrayT) 
Copy an array
 
CopyT(VariableArrayVariableArrayT, T) 
Copy an array
 
CopyTItem, T(VariableArrayVariableArrayTItem, T, T) 
Copy an array
 
CountTrue 
Returns an integer variable equal to the number of array elements that are true.
 
CutT 
Returns a cut of the argument. Cut is equivalent to random(infer()).
 
Dirichlet(Double) 
Creates a Dirichletdistributed random variable with a specified set of pseudocounts.
 
Dirichlet(Vector) 
Creates a Dirichletdistributed random variable with a set of pseudocounts specified
by a Vector object.
 
Dirichlet(VariableVector) 
Creates a Dirichletdistributed random variable with pseudocounts specified by a random variable.
 
Dirichlet(Range, Vector) 
Creates a Dirichletdistributed random variable with the dimensionality specified by
a Range object and the pseudocounts specified by a Vector object.
 
Dirichlet(Range, VariableVector) 
Creates a Dirichletdistributed random variable with the dimensionality specified by
a Range object and the pseudocounts represented by a random variable.
 
Dirichlet(Range, Double) 
Creates a Dirichletdistributed random variable with the dimensionality specified by
a Range object and a specified set of pseudocounts.
 
DirichletSymmetric(Int32, VariableDouble) 
Creates a symmetric Dirichletdistributed random variable with a specified dimension
and a common pseudocount, which is represented by a random variable.
 
DirichletSymmetric(Int32, Double) 
Creates a symmetric Dirichletdistributed random variable with a specified dimension
and a common pseudocount.
 
DirichletSymmetric(Range, VariableDouble) 
Creates a symmetric Dirichletdistributed random variable with the dimension specified by
a Range object and a common pseudocount, which is represented by a random variable.
 
DirichletUniform(Int32) 
Create a uniform Dirichletdistributed random variable with a specified dimension.
 
DirichletUniform(Range) 
Creates a uniform Dirichletdistributed random variable with dimension specified by a
Range object.
 
DirichletUniform(VariableInt32) 
Create a uniform Dirichletdistributed random variable with a specified dimension.
 
Discrete(Double) 
Creates a random variable that is statistically defined by a Discrete distribution with a specified
set of probabilities.
 
Discrete(Vector) 
Creates a random variable that is statistically defined by a Discrete distribution with the set of possible
values specified by a Vector object.
 
Discrete(VariableVector) 
Creates a random variable that is statistically defined by a Discrete distribution with the probabilities of
the possible values specified by an Vector random variable.
 
Discrete(Range, Vector) 
Creates a random variable that is statistically defined by a Discrete distribution with the number of possible
values specified by a Range object and the probabilities by a Vector object.
 
Discrete(Range, VariableVector) 
Creates a random variable that is statistically defined by a Discrete distribution with the number of
possible values specified by a Range object and the probabilities of
the possible values specified by an Vector random variable.
 
Discrete(Range, Double) 
Creates a random variable that is statistically defined by a Discrete distribution with a specified
number of possible values, and a corresponding set of probabilities.
 
DiscreteFromLogProbs 
Creates a random int variable x where p(x=k) is proportional to exp(logProbs[k]), i.e. the softmax function of the logProbs.
 
DiscreteUniform(Int32) 
Create a random integer by drawing uniformly from the range 0..(size1)
 
DiscreteUniform(Range) 
Create a random integer by drawing uniformly from a range.
 
DiscreteUniform(VariableInt32) 
Creates a random variable that is statistically defined by a Discrete distribution with the number
of possible values specified by an int random variable.
 
DiscreteUniform(Range, VariableInt32) 
Creates a random variable that is statistically defined by a uniform Discrete distribution with the number
of possible values specified by Range object, and the upper bound specified by a random variable.
 
Double(IModelExpressionInt32) 
Create a doubleprecision random variable that is constrained to equal the given integer expression.
 
Double(VariableInt32) 
Create a doubleprecision random variable that is constrained to equal the given integer variable.
 
EnumDiscreteTEnum(Double) 
Creates a random variable with a Discrete distribution with specified probabilities for each of the
values of the specified enum type.
 
EnumDiscreteTEnum(Vector) 
Creates a random variable with a Discrete distribution with the probabilities for each of
the values of the enum type specified by a Vector object.
 
EnumDiscreteTEnum(VariableVector) 
Creates a random variable with a Discrete distribution using probabilities specified by a Vector
object for each of the values of the specified enum type.
 
EnumDiscreteTEnum(Range, Vector) 
Creates a random variable with a Discrete distribution with the number of possible values
specified by a Range object and the probabilities for each of
the values of the enum type specified by a Vector object.
 
EnumDiscreteTEnum(Range, Double) 
Creates a random variable with a Discrete distribution with the dimension specified by a Range
object and specified probabilities for each of the values of the enum type.
 
EnumToIntTEnum 
Creates a random int variable corresponding to a random enum variable. The returned
variable can be used as the condition for a Switch or Case block.
 
EnumUniformTEnum 
Creates a random variable with a Discrete distribution with a uniform distribution.
 
EnumUniformTEnum(Range) 
Creates a random variable with a Discrete distribution with the dimension specified by a Range
object and a uniform distribution.
 
Exp 
Returns a variable which takes e to the power of another random variable
 
ForEach 
Creates a new 'for each' block
 
FunctionEvaluate 
Evaluate a random function at a point
 
GammaFromMeanAndVariance(Double, Double) 
Creates a Gammadistributed random variable with specified mean and variance parameters.
 
GammaFromMeanAndVariance(VariableDouble, VariableDouble) 
Creates a Gammadistributed random variable with its mean and variance parameters represented by random variables.
 
GammaFromShapeAndRate(Double, Double) 
Creates a Gammadistributed random variable with specified shape and rate parameters.
 
GammaFromShapeAndRate(VariableDouble, VariableDouble) 
Creates a Gammadistributed random variable with its shape and rate parameters represented by random variables.
 
GammaFromShapeAndScale(Double, Double) 
Creates a Gammadistributed random variable with specified shape and scale parameters.
 
GammaFromShapeAndScale(VariableDouble, VariableDouble) 
Creates a Gammadistributed random variable with its shape and scale parameters represented by random variables.
 
GaussianFromMeanAndPrecision(Double, Double) 
Creates a Gaussiandistributed random variable with specified mean and precision.
 
GaussianFromMeanAndPrecision(VariableDouble, VariableDouble) 
Creates a Gaussiandistributed random variable with mean and precision represented
by random variables.
 
GaussianFromMeanAndVariance(Double, Double) 
Creates a Gaussiandistributed random variable with specified mean and variance.
 
GaussianFromMeanAndVariance(VariableDouble, VariableDouble) 
Creates a Gaussiandistributed random variable with the mean and variance represented by random variables.
 
GaussianFromMeanAndVariance(VariableDouble, Double) 
Creates a Gaussiandistributed random variable with a specified variance, and the mean
represented by a random variable.
 
GaussianListFromMeanAndPrecision(ISparseListDouble, ISparseListDouble) 
Returns a random variable over a sparse vector domain where each element is statistically
defined in terms of the corresponding mean and precision elements in sparse vectors
of means and precisions
 
GaussianListFromMeanAndPrecision(ISparseListDouble, VariableISparseListDouble) 
Returns a random variable over a sparse list domain where each element is statistically
defined in terms of the corresponding mean and precision elements in sparse vectors
of means and precisions
 
GaussianListFromMeanAndPrecision(VariableISparseListDouble, ISparseListDouble) 
Returns a random variable over a sparse vector domain where each element is statistically
defined in terms of the corresponding mean and precision elements in sparse vectors
of means and precisions
 
GaussianListFromMeanAndPrecision(VariableISparseListDouble, VariableISparseListDouble) 
Returns a random variable over a sparse list domain where each element is statistically
defined in terms of the corresponding mean and precision elements in sparse vectors
of means and precisions
 
GetAttributesAttributeType 
Get all attributes of this variable having type AttributeType.
 
GetContainersT 
List of containers for this variable (ForEachBlock, IfBlock, etc.)
 
GetDomainType 
Gets the domain type of a Variable<T>
 
GetExpression 
Gets a syntax tree which refers to this variable in MSL.
 
GetFirstAttributeAttributeType 
Gets the first attribute of the specified type
 
GetItem(VariableString, VariableInt32) 
Creates a character random variable representing the character on a given position inside a given string.
 
GetItem(VariableVector, VariableInt32) 
Copy an element of a vector.
 
GetItemsT(VariableIListT, VariableArrayInt32) 
Gets a variable array containing (possibly duplicated) items of a source array
 
GetItemsT(VariableT, VariableArrayInt32) 
Gets a variable array containing (possibly duplicated) items of a source array
 
GetItemsT(VariableArrayT, VariableArrayInt32) 
Gets a variable array containing (possibly duplicated) items of a source array
 
GetItemsTItem, T(VariableArrayTItem, T, VariableArrayInt32) 
Gets a variable array containing (possibly duplicated) items of a source array
 
GetValueRange 
Get the ValueRange attribute of this variable, if any has been set, otherwise throws an exception.
 
GetValueRange(Boolean) 
Get the ValueRange attribute of this variable, if any has been set.
 
HasAttributeAttributeType 
Determines if this variable has at least one attribute of type AttributeType.
 
IArrayT(Range) 
Creates a 1D random variable IArray with a specified size.
 
IArrayT(Range, Range) 
Creates a 2D random variable array with specified dimensions.
 
IArrayT(VariableArrayT, Range) 
Creates a 1D random variable IArray that contains a jagged array of 1D random variables.
 
IArrayT(VariableArray2DT, Range) 
Creates a 1D random variable IArray that contains a jagged array of 2D random variables.
 
IArrayT(VariableArrayT, Range, Range) 
Create a 2D random variable IArray2D that contains a jagged array of 1D random variables.
 
IArrayTItem, TArray(VariableArrayTItem, TArray, Range) 
Create a 1D IArray of 1D random variable arrays
 
If 
Opens a stochastic if statement, active when the argument is true.
 
IfNot 
Opens a stochastic if statement, active when the argument is false.
 
IListT(Range) 
Creates a 1D random variable IList with a specified size.
 
IListT(VariableArrayT, Range) 
Creates a 1D random variable IList that contains a jagged array of 1D random variables.
 
IListTItem, TArray(VariableArrayTItem, TArray, Range) 
Create a 1D IList of 1D random variable arrays
 
InnerProduct(VariableArrayDouble, VariableVector) 
Returns a double random variable which is the inner product of two vector variables.
 
InnerProduct(VariableVector, VariableVector) 
Returns a double random variable which is the inner product of two vector variables.
 
IsBetween 
Returns a boolean random variable indicating if the supplied double random variable is between
the specified limits.
 
IsDefinedInContext 
True if the variable is defined in the given condition context.
 
IsPositive 
Returns a boolean random variable indicating if the supplied double random variable is positive.
 
JaggedSubarrayT  
Linear 
Adds a linear factor between two int variables (max product only!).
 
LinearTrunc 
Adds a truncated linear factor between two int variables (max product only!).
 
Log 
Returns a variable equal to the natural logarithm of d
 
Logistic 
Creates a variable equal to 1/(1+exp(x))
 
LookupOperatorFactor 
Retrieves the factor method for a given operator and parameter types.
 
MatrixMultiply 
Returns a 2D array of variables which is the matrix product of two other 2D arrays of variables
 
MatrixTimesScalar 
Create a matrix variable whose [i,j] entry equals a[i,j]*b
 
MatrixTimesVector 
Returns a Vector variable which is the product of a Matrix variable with a Vector variable
 
Max 
Returns a double variable which is the max of two double variables
 
Multinomial(Range, VariableVector) 
Creates an array x of random integers where x[i] is the number of times that value i is drawn in the given number of trials.
 
Multinomial(VariableInt32, Vector) 
Creates an array x of random integers where x[i] is the number of times that value i is drawn in the given number of trials.
 
Multinomial(VariableInt32, VariableVector) 
Creates an array x of random integers where x[i] is the number of times that value i is drawn in the given number of trials.
 
MultinomialList 
Creates a list x of random integers where x[i] is the number of times that value i is drawn in the given number of trials.
 
NewT 
Creates a variable with no statistical definition.
 
ObservedT(IListT) 
Creates a variable array and observes it.
 
ObservedT(T) 
Creates a variable and observes it.
 
ObservedT(T) 
Creates a 2D variable array and observes it.
 
ObservedT(T) 
Creates a variable array and observes it.
 
ObservedT(IListT, Range) 
Creates a variable array and observes it.
 
ObservedT(T, Range) 
Creates a variable array and observes it.
 
ObservedT(IListIListT, Range, Range) 
Creates a jagged variable array and observes it.
 
ObservedT(T, Range, Range) 
Creates a 2D variable array and observes it.
 
ObservedT(T, Range, Range) 
Creates a jagged variable array and observes it.
 
ObservedT(T, Range, Range, Range) 
Creates a jagged variable array and observes it.
 
Poisson(Double) 
Creates a Poissondistributed random variable with a specified mean.
 
Poisson(VariableDouble) 
Creates a Poissondistributed random variable with the mean represented by a random variable.
 
Potts(VariableBoolean, VariableBoolean, VariableDouble) 
Adds a Potts factor between two boolean variables (max product only!).
 
Potts(VariableInt32, VariableInt32, VariableDouble) 
Adds a Potts factor between two int variables (max product only!).
 
ProductExp 
Returns a Gaussian variable which is the product of A times the exponential of B.
 
RandomT(IDistributionT) 
Creates a random variable with a specified prior distribution.
 
RandomT, TDist(VariableTDist) 
Creates a random variable with a specified prior distribution.
 
RegisterOperatorFactor 
Registers a factor method against a particular operator.
 
RemoveAllAttributesAttributeType 
Remove all attributes of the specified type
 
Repeat 
Creates a new 'repeat' block
 
ReplicateT(VariableT, Range) 
Replicates a value multiple times.
 
ReplicateT(VariableArrayT, Range) 
Replicates an array multiple times.
 
ReplicateT(VariableArrayVariableArrayT, T, Range) 
Replicates an array multiple times.
 
ReplicateTItem, T(VariableArrayVariableArrayTItem, T, T, Range) 
Replicates an array multiple times.
 
Rotate 
A random vector equal to the vector (x,y) rotated by an angle about the origin.
 
SetSparsity 
Sets the Sparsity attribute of this variable, replacing any previously set.
 
SetValueRange 
Sets the ValueRange attribute of this variable, replacing any previously set.
 
Softmax(VariableISparseListDouble) 
Creates a vector variable y where y[i] = exp(x[i])/(sum_j exp(x[j])). y has the same length as x.
 
Softmax(VariableIListDouble) 
Creates a vector variable y where y[i] = exp(x[i])/(sum_j exp(x[j])). y has the same length as x.
 
Softmax(VariableArrayDouble) 
Creates a vector variable y where y[i] = exp(x[i])/(sum_j exp(x[j])). y has the same length as x.
 
Softmax(VariableVector) 
Creates a vector variable y where y[i] = exp(x[i])/(sum_j exp(x[j])). y has the same length as x.
 
String(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings with length
in given bounds.
 
String(VariableInt32, VariableInt32, VariableDiscreteChar) 
Creates a string random variable from a uniform distribution over all strings with length
in given bounds. String characters are restricted to be non zero probability characters under the given character distribution.
 
StringCapitalized 
Creates a string random variable from a uniform distribution over all strings
consisting of an uppercase letter followed by one or more lowercase letters.
 
StringCapitalized(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
consisting of an uppercase letter followed by one or more lowercase letters, with length in specified bounds.
 
StringDigits 
Creates a string random variable from a uniform distribution over all nonempty strings
of digits (see CharDigit).
 
StringDigits(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of digits (see CharDigit) with length in given bounds.
 
StringFormat(VariableString, VariableString) 
Replaces argument placeholders such as {0}, {1} etc with arguments having the corresponding index,
similar to what Format(String, Object) does.
 
StringFormat(VariableString, VariableArrayString) 
Replaces argument placeholders such as {0}, {1} etc with arguments having the corresponding index,
similar to what Format(String, Object) does.
 
StringFromArray 
Creates a string random variable from an array of characters.
 
StringLetters 
Creates a string random variable from a uniform distribution over all nonempty strings
of letters (see CharLetter).
 
StringLetters(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of letters (see CharLetter) with length in given bounds.
 
StringLettersOrDigits 
Creates a string random variable from a uniform distribution over all nonempty strings
of letters or digits (see CharLetterOrDigit).
 
StringLettersOrDigits(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of letters or digits (see CharLetterOrDigit) with length in given bounds.
 
StringLower 
Creates a string random variable from a uniform distribution over all nonempty strings
of lowercase letters (see CharLower).
 
StringLower(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of lowercase letters (see CharLower) with length in given bounds.
 
StringNonWord 
Creates a string random variable from a uniform distribution over all nonempty strings
of nonword characters (see CharNonWord).
 
StringNonWord(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of nonword characters (see CharNonWord) with length in given bounds.
 
StringOfLength(VariableInt32) 
Creates a string random variable from a uniform distribution over all strings of given length.
 
StringOfLength(VariableInt32, VariableDiscreteChar) 
Creates a string random variable from a uniform distribution over all strings of given length.
String characters are restricted to be non zero probability characters under the given character distribution.
 
StringUniform 
Creates a string random variable from a uniform distribution over all possible strings.
 
StringUpper 
Creates a string random variable from a uniform distribution over all nonempty strings
of uppercase letters (see CharUpper).
 
StringUpper(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of uppercase letters (see CharUpper) with length in given bounds.
 
StringWhitespace 
Creates a string random variable from a uniform distribution over all nonempty strings
of whitespace characters (see CharWhitespace).
 
StringWhitespace(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of whitespace characters (see CharWhitespace) with length in given bounds.
 
StringWord 
Creates a string random variable from a uniform distribution over all nonempty strings
of word characters (see CharWord).
 
StringWord(VariableInt32, VariableInt32) 
Creates a string random variable from a uniform distribution over all strings
of word characters (see CharWord) with length in given bounds.
 
SubarrayT(VariableIListT, VariableArrayInt32) 
Gets a variable array containing different items of a source list
 
SubarrayT(VariableT, VariableArrayInt32) 
Gets a variable array containing different items of a source array.
 
SubarrayT(VariableArrayT, VariableArrayInt32) 
Gets a variable array containing different items of a source list
 
SubarrayT(VariableArrayT, VariableArrayVariableInt32, IListInt32) 
Gets a variable array containing different items of a source list.
 
SubarrayTItem, T(VariableArrayTItem, T, VariableArrayInt32) 
Gets a variable array containing different items of a source list
 
Substring 
Creates a string random variable which is a substring of a given string.
 
Subvector 
Copy a contiguous subvector of a random vector.
 
Sum(VariableIListDouble) 
Returns a double variable which is the sum of the elements of an array variable.
For sum of two variables, use the + operator.
 
Sum(VariableDouble) 
Returns a double variable which is the sum of the elements of an array variable.
For sum of two variables, use the + operator.
 
Sum(VariableVector) 
Returns a Vector(VariableDouble) variable which is the sum of the elements of an array variable.
 
Sum(VariableIListVector) 
Returns a Vector(VariableDouble) variable which is the sum of the elements of an array variable.
 
Sum_Expanded 
Returns a double variable which is the sum of the elements of an array variable.
For sum of two variables, use the + operator.
 
SumWhere 
Returns a double random variable which is the inner product of a array of binary variables and a vector variable.
 
Switch 
Opens a stochastic switch statement using the specified condition variable. This is equivalent
to creating a set of identical Variable.Case() statements for each value of i. Within a switch block,
you can use the variable i as an array index.
 
TruncatedGaussian 
Returns a random variable that is statistically defined by a truncated Gaussian distribution
with specified mean, variance and bounds.
 
Vector 
Create a random Vector from values in an array.
 
VectorGaussianFromMeanAndPrecision(Vector, PositiveDefiniteMatrix) 
Creates a Gaussiandistributed random vector with a specified mean and precision matrix.
 
VectorGaussianFromMeanAndPrecision(VariableVector, VariablePositiveDefiniteMatrix) 
Creates a vector Gaussiandistributed random vector with the mean and precision matrix represented
by random variables.
 
VectorGaussianFromMeanAndVariance(Vector, PositiveDefiniteMatrix) 
Creates a Gaussiandistributed random vector from a mean vector and variance positive definite matrix.
 
VectorGaussianFromMeanAndVariance(VariableVector, PositiveDefiniteMatrix) 
Creates a Gaussiandistributed random vector from a mean vector and variance positive definite matrix.
 
VectorGaussianFromMeanAndVariance(VariableVector, VariablePositiveDefiniteMatrix) 
Creates a Gaussiandistributed random vector from a mean vector and variance positive definite matrix.
 
WishartFromShapeAndRate 
Creates a Wishartdistributed random matrix with the shape and rate represented by random variables.
 
WishartFromShapeAndScale(Double, PositiveDefiniteMatrix) 
Creates a Wishartdistributed random variable with specified shape and scale.
 
WishartFromShapeAndScale(VariableDouble, VariablePositiveDefiniteMatrix) 
Creates a Wishartdistributed random matrix with the shape and scale represented by random variables.

Name  Description  

ArrayVariable 
The array that this variable is an element of (otherwise null).
 
Definition 
Gets the definition of this variable in the current context. Will return
null if the variable is undefined or if it is only defined in a subcontext (such as an If or Switch).
 
IsArrayElement 
Whether this variable is an element of an array
 
IsDefined 
True if the variable is defined in the current condition context.
 
IsLoopIndex  
IsObserved 
Is Observed property
 
IsReadOnly 
Read only property
 
Name 
Name
 
NameInGeneratedCode 
Name used in generated code

Name  Description  

HasObservedValueObservedValue 
Observed value property
 
IModelExpressionName 