ContMult
Creates a new continuous variable with values contVar[i]*numberToMultiply, returns a reference to the new variable.
Syntax
ContMult(contVar, numberToMultiply)
Parameters
Parameter |
Type |
Description |
---|---|---|
contVar |
variableReference |
Reference to the variable. |
numberToMultiply |
number |
The result values will be contVar[i]*numberToMultiply |
Return
Creates a new continuous variable with values contVar[i]*numberToMultiply, returns a reference to the new variable.
Examples
Python
import nex
doc = nex.GetActiveDocument()
coeff = -1.0
doc["invertedFP01"] = nex.ContMult(doc["FP01"], coeff)
# you can also use arithmetic operations on continuous variables:
doc["average of FP01 and FP02"] = ( doc["FP01"] + doc["FP02"] ) / 2
NexScript
doc = GetActiveDocument()
coeff = -1.0
doc["invertedFP01"] = ContMult(doc["FP01"], coeff)