Hub
Pricing About
  • Software
  • Blog
  • Forum
  • Events
  • Documentation
  • About KNIME
  • KNIME Community Hub
  • Nodes
  • Math Formula
NodeNode / Manipulator

Math Formula

Manipulation Column Convert & Replace Streamable
Drag & drop
Like
Copy short link

This node evaluates a mathematical expression based on the values in a row. The computed results can be either appended as new column or be used to replace an input column. Available variables are the values in the corresponding row of the table (left list in the dialog). Commonly used functions are shown in the list "Mathematical Functions". There are also some constants available, such as pi (the ratio of the circumference of a circle to its diameter), e (the base of the natural logarithms), the total number of rows in the table, and some other column based constants ( constant category of functions).

This node uses JEP , the Java Math Expression Parser .

Column based constants such as COL_MIN(col_name) will be calculated in advance (if necessary).

You can reference the integer flow variables like this: $${IflowVar}$$ , the floating point flow variables like this: $${DflowVar}$$ .

Reference the columns with the form: $colName$

When any of the used columns contains a missing value, the result is missing, just like when the result would be NaN, infinite value, or outside of the 32 bit signed integer range when that is requested.

NaN values act as value true in boolean expressions and compared to anything (including NaN) in any way (including ==, but not !=, which is like !(... == ...)) is false (0).

Please note the expressions are case sensitive.

Node details

Input ports
  1. Type: Table
    Input data
    Any input data
Output ports
  1. Type: Table
    Output data
    Input data amended with math column.

Extension

The Math Formula node is part of this extension:

  1. Go to item

Related workflows & nodes

  1. Go to item
    Moritz's First Upload
    Simple workflow doing nothing special
    moritz.heine > Public > Moritz_First_Upload
    moritz.heine
  2. Go to item
    KNIME_project
    troelsotte > Public > KNIME_project
    troelsotte
  3. Go to item
    2019_07_15_Forum_calculate_next
    iris > Public > 2019_07_15_Forum_calculate_next
    iris
  4. Go to item
    math expression from variable
    elsamuel > Public > math expression from variable
    elsamuel
  5. Go to item
    Funny Math
    Funny Math Loopless Pattern
    This workflow demonstrates how to use Math Formula node to create both sequence and seque…
    ipazin > Public > 2020_10_06_Funny_Math
    ipazin
  6. Go to item
    4
    lina3 > Public > Lab 3 > 4
    lina3
  7. Go to item
    Insert Serial Number
    Serialnumber Insert Insertcolumn
    This workflow helps inserting a column containing the serial number.
    omprakashjena > Public > Workflows > Insert Serial Number
    omprakashjena
  8. Go to item
    Substract values of two consecutive rows
    kathrin > Forum Questions > Substract values of two consecutive rows
    kathrin
  9. Go to item
    String Manipulation, Math Formula and Rule Engine Example
    ETL Data manipulation String manipulation
    +7
    This workflow shows three different data manipulation operations, namely: - create three …
    knime > Examples > 02_ETL_Data_Manipulation > 04_Transformation > 02_StringManipulation_MathFormula_RuleEngine
    knime
  10. Go to item
    Cost_per_Attendee
    This workflow calculates cost per attendee per each Report. Logic is contained in Math Fo…
    ipazin > Public > 2019_08_02_Cost_per_Attendee
    ipazin
  1. Go to item
  2. Go to item
  3. Go to item
  4. Go to item
  5. Go to item
  6. Go to item

KNIME
Open for Innovation

KNIME AG
Talacker 50
8001 Zurich, Switzerland
  • Software
  • Getting started
  • Documentation
  • E-Learning course
  • Solutions
  • KNIME Hub
  • KNIME Forum
  • Blog
  • Events
  • Partner
  • Developers
  • KNIME Home
  • KNIME Open Source Story
  • Careers
  • Contact us
Download KNIME Analytics Platform Read more on KNIME Business Hub
© 2023 KNIME AG. All rights reserved.
  • Trademarks
  • Imprint
  • Privacy
  • Terms & Conditions
  • Credits