Open in Matlab

This node opens a local Matlab session and pushes the data table from Knime into Matlab for rapid prototyping. Starting from the Matlab variable containing the KNIME data, a script can be developed and tested, before putting it into a Matlab snippet node.

The input data table is converted into a Matlab type variable (dataset, table, container.Map or structure), and made available in the Matlab workspace as a variable named kIn. There is also a variable columnMapping, that is a structure allowing to associate the KNIME column names with the Matlab variable names (not needed if the dataset or table type is used).

This node needs a Matlab installation on the local machine!
If Matlab is not running, the node launches an instance of the Matlab desktop. It is recommended to let KNIME launch Matlab. The node can detect open Matlab instances, but this is not foolproof. The working directory of Matlab will be changed to the location where KNIME stores the m-file to load the data in the workspace (manually you'll have to change directory into the temp-dir of the JVM that runs KNIME).


  • Snippet input variable name: kIn
  • Snippet output variable name: mOut
  • Supported Matlab types: dataset, table, struct or container.Map
  • While the script input type is defined by the preferences, the output type will be inferred from the output variable
  • The column names for dataset and table Matlab data types are taken from the object properties (VariableDescriptions/VarDesription). For the other types, they will be the same as the input as long as the header does not change.
  • Templates repositories are controlled via the preferences (Menu > KNIME > Preferences > KNIME > Matlab Scripting).

Further reading:
Further documentation can be found on the wiki.
To understand how to use flow variables in the script, please consult RGG XML.

Input Ports

A data table pushed to Matlab

Output Ports

This node has no output ports


This node has no views


  • No workflows found



You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.