How to multiply terms in one column by frequency number in another column

Hi, Folks. KNIME newbie here. This seems like something that would be easy to do, but I haven’t been able to figure it out despite lots of searching. So please be patient with me :slight_smile:

I have one column with the title of articles – so, a string. And then another column with a number, like pageviews on that article.

When I do a tag cloud or something like that, I want to look at the title words multiplied by the frequency they were viewed (pageviews). So I want to assign a weight to the first column using the number column.

How would I go about doing that? Thanks in advance!

Hi @FreeRangePamela,

you can simply convert your String to a Term Column with the “String to Term” Node. Afterwards you can set both the Term Column and the Weigth (or Size) Column in the configure dialog of the Tag Cloud Nodes (works for the usual Visualization and the JavaScript Node). The Terms will be enlarged by the size value. Is that what you were looking for?

That seems to work. Thank you! I was making it a little more complex than it needed to be.