I want to count specific value from column

Table

Hello,

I am aiming to get the count of specific text from a column.
With the example attached, I have 2 columns : Data and Status. From Data column, I have 4 unique values and with different statuses from Status column.

from the output table, i would like to come up with the table with the unique Data and the count of status.
Please take note that the status may have pretext to it or in other words, i have to use regex

Hi @ayemotep and welcome to KNIME Forum

I.m.o spltting the Status column (using a cell splitter, string manipulation, regex node) into anytext and status is the key to the solution (create a pivot table). So more information is needed about the content ot the Status column. Is it possible to provide some sample/dummy records? That makes is easier for the communtiy to find a solution for you.
gr. Hans

3 Likes

Make sure you lowercase your data when splitting

2 Likes

Hi @ayemotep , and welcome to the Knime Community.

I put something together that looks like this:
image

Input data (same as what you have):
image

Results:
image

Here’s the workflow: Count specific text from column.knwf (8.5 KB)

4 Likes

Hi @bruno29a , Thank you for your inputs.

It seems that Column expression node is not yet available in my Knime.
Can you help me on how can i import it?

Hi @ayemotep , sure, there are a few ways to do this. Here are 2 easiest ways to do it:

1). You can open import my workflow and open it, Knime should notify you that Column Expressions is missing and it will ask if you want to install it, and you can let Knime install it for you.

2). You can go to the Knime hub and get the Column Expressions from there:

You can literally drag the node from there to your workflow, and Knime will notify you that you need to install the relevant extensions, and will prompt you if it can do so. Let Knime install the extension.

2 Likes

Hello @ayemotep,

in general you can check out this guide from KNIME Docs on how to add more nodes to your KNIME:

https://docs.knime.com/latest/analytics_platform_installation_guide/index.html#_installing_extensions_and_integrations

Br,
Ivan

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.