Looking up column header of multiple values

Hi there, I am very familiar with VBA, however we need to process big data for multiple files and we would like to use KNIME for this purpose. I am trying to average all the background ratios corresponding to a certain ID. In the example table below, not sure how to add it as a table, I have simplified how the table looks like and what I need. I have now extracted all unique background IDs that I have to look up for each ID with KNIME. Now I am stuck in annotating the column header corresponding having this background ID. After this I need to lookup in another column the ratio for this background ID, and average them and put them in a new column next to the corresponding compound ID. I am trying to break the process in little steps, though I am uncertain whether I am doing it properly. Hope someone can help me!

(The dots indicate rows and columns with more data)

Hi @FKp and welcome to the Knime Community.

You can use the column() function from the Column Expressions node where you can pass the name of a column as parameter.

For example column("Background Compound1") or column("Background CompoundX").

You can also pass a variable as dynamic values. For example column(variable("var_name"))

Here’s a demo I created a while ago about this:


Thanks a lot, I have managed to fix it! :slight_smile:

1 Like