What is a TERR inline expression?
An inline expression is when you are using TERR directly on the axis of a visualization, as a custom expression. This is done by using of the functions of the expression language that are prefixed with TERR_ in the expression. See the full list in the statistical functions section of the help.
If my inline expression can no longer be executed in my version of Spotfire, what can I do?
Convert your inline expression into an Expression function instead. Expression functions can be trusted by members of the script author group as described in the documentation.
Below is an example of how to convert an inline expression to an expression function.
The visualization in this example uses the R function kmeans to color the markers in the scatter plot.
Here is what the inline expression looks like:
To convert this inline expression to an expression function we first follow the steps in creating an expression function. When it comes to adding the script code we will paste the following snippet:
nkmeans <-function(input1,input2,input3) { km <- kmeans(data.frame(input1, input2, input3),3)$cluster km } output <- nkmeans(input1,input2,input3)
Here is a screenshot of the dialog:
Then, on the color axis of the visualization, we will now use the new expression function instead of the inline expression:
Then we are done. The visualization looks like before; the only difference is the expression on the color axis.
Read more about data function trust in the following articles
Recommended Comments
There are no comments to display.