Icon

02 Flow Variables and Components

02 Flow Variables and Components - Exercise

This workflow shows a hands-on exercise in the L2-DW Introduction to KNIME Analytics Platform for Data Wranglers - Advanced course

Task 1: Use Flow VariablesRead the JoinedCountryTable.table file by executing the Table Reader node. This table contains information about the demographics,geolocation, and travel risks in the different countries/territories in 2020. Your task is to find the northmost country/territory in the data viathe following steps:1. Calculate first the maximum latitude value in the data2. Transform it into a flow variable3. Filter the data by this flow variable Task 2: Create a ComponentsYour task is to extend the workflow from the previous task into a component that returns the northmost country/region by continent via thefollowing steps:1. Create a Value Selection Configuration node to select one of the UN continental regions in the data2. Add a Row Filter node before the GroupBy node to filter the data by the selected continent3. Encapsulate the workflow into a component. Make sure you add a data output to the component. Task 3: Use a Shared ComponentYour task is to compare how fast/slow the population increases in different countries. Build a choropleth world map via the following steps:1. Drag and drop the Choropleth World Map shared component from the KNIME Hub2. Select the Country/Territory and Change (population) columns in its configuration dialog3. Open the component’s interactive view JoinedCountryData.tableNode 3Node 4Node 5 ChoroplethWorld Map Table Reader GroupBy Table Rowto Variable Rule-basedRow Filter Northmost countryby continent Task 1: Use Flow VariablesRead the JoinedCountryTable.table file by executing the Table Reader node. This table contains information about the demographics,geolocation, and travel risks in the different countries/territories in 2020. Your task is to find the northmost country/territory in the data viathe following steps:1. Calculate first the maximum latitude value in the data2. Transform it into a flow variable3. Filter the data by this flow variable Task 2: Create a ComponentsYour task is to extend the workflow from the previous task into a component that returns the northmost country/region by continent via thefollowing steps:1. Create a Value Selection Configuration node to select one of the UN continental regions in the data2. Add a Row Filter node before the GroupBy node to filter the data by the selected continent3. Encapsulate the workflow into a component. Make sure you add a data output to the component. Task 3: Use a Shared ComponentYour task is to compare how fast/slow the population increases in different countries. Build a choropleth world map via the following steps:1. Drag and drop the Choropleth World Map shared component from the KNIME Hub2. Select the Country/Territory and Change (population) columns in its configuration dialog3. Open the component’s interactive view JoinedCountryData.tableNode 3Node 4Node 5 ChoroplethWorld Map Table Reader GroupBy Table Rowto Variable Rule-basedRow Filter Northmost countryby continent

Nodes

Extensions

Links