Icon

01.Game Data App - Exercise

<p>This workflow finishes the implementation of a Game Data App by adding the Page 3-Form, and Page 4-Dashboard. The result is a customized and interactive application that is ready to be deployed as a data app on KNIME Business Hub.</p>
Annotations and comments
  • Part 2 - Building and Deploying a Data App Exercise 01 Game Data App
  • Page 4a Show an interactive dashboard with game statistics
  • Learning objective: In this exercise you'll learn how to build and deploy a data app with components, interactivity, and other configurations. Workflow description: This workflow finishes the implementation of a Game Data App by adding the Page 3-Form, and Page 4-Dashboard. The result is a customized and interactive application that is ready to be deployed as a data app on KNIME Business Hub. You'll find the instructions to the exercises in the yellow annotations.
  • Here we read the match results data and prepare it for the visualization. We want to show a bar chart and let the user select whether it displays the most mistaken or most correct flags.
  • Step 3. Set up the widget You want the user to select whether to display the hardest (most mistaken) or easiest (most correct) flags, interactively. Hence, With a Single Selection Widget node, create a menu to select between two options - Hardest and Easiest. Pass the flow variable with the user selection to the Row Filter node and configure it to keep correct or wrong answers according to the flow variable.
  • Step 4. Create Page 4a - Dashboard Component Select all the nodes and components in Page 4a and wrap them up into a component. Name it "Page 4a". Rearrange the component composite view with the layout editor. IMPORTANT: You want the user to update the Bar Chart view after selecting a new configuration. What is missing to enable the view update?
  • The first two pages are already configured. Page 1 shows a Welcome page while setting up the game session, and Page 2 let the user play the game (3 iterations)
  • Page 3 Show match results and collect user feedback
  • Step 1. Configure the Data App Flowchart to guide the user through the flow Search the Data App Flowchart verified component on the KNIME Community Hub and add it to the workflow -> https://kni.me/c/-o_CLuu7-qrfguqE With a Table Creator node, define the steps of the data app (Welcome, Play, Form, Dashboard) and set page 3 as the active one. Configure the Data App Flowchart component to use the correct columns.
  • Step 2. Create the Page 3 - Form component Select all the nodes and components in the Page 3 orange annotation. Wrap them up into a component. Name it "Page 3". Connect the Page 3 component to the main flow (Variable Loop End node) via flow variable connection Open the Page 3 component and rearrange its composite view via the Layout editor.
  • Page 1 Set up the match
  • Page 2 Play the game
  • Refresh Button Widget node before the Single Selection Widget node OR Enable automatic re-execution on the Single Selection Widget node PULL FOR THE ANSWER
  • Data App Flowchart
  • (Optional) Page 4b
  • Step 5. Validate user input data You want to check whether the user entered valid data or just left the default entries. With a Row Filter node, remove the entry if the email address is "example@email.com" (default) Define a conditional path by adding an Empty Table Switch node. Connect the first port of the Empty Table Switch node (non-empty table) to Page 4a - the user sees the dashboard Connect the second port of the Empty Table Switch node (empty table) to Page 4b - the user sees an error message
  • Step 6. Deployment Upload this workflow to KNIME Business Hub: Right click the workflow in the Explorer and select Upload. Reset the workflow before upload. In the Hub browser UI: Create a new workflow version. Deploy this workflow as a Data app. In Advanced settings, select the User execution scope, and create the deployment Execute the Data app.
  • countries
  • read global results.csv
  • newsletter
  • scan values
  • age
  • rate
  • sort alphabetically
  • feedback
  • First name
  • Last name
  • Email
  • read countries
  • rate text
  • Provide info
  • country
  • guesses per flag
  • use dummy data if no current match results
  • read local match_results.csv
  • round score
  • dummy results
  • column rename
  • read internal match_results.csv
  • replace internal match_results.csv
  • 0: incorrect 1: correct 2: missing answer
  • Incorrect
  • Correct
  • Points=maxIterations
  • Points = -1
  • Points=0
  • Compare guess
  • Enable username and session variables
  • syntax check
  • correct syntax
  • Header
  • css_header
  • colors
  • image size
  • logo image in base64 format.
  • predefined colors text
  • predefined colors background
  • predefined colors flowchart bg
  • predefined colors flowchart activation
  • Background Color Code
  • image base64 format
  • text Color Code
  • flowchart bg Color Code
  • flowchart activation Color Code
  • rename to correct-name
  • Select image column
  • Select names column
  • Show image
  • Filter first entry
  • Export correct name
  • score so far
  • calculate current round
  • Rename names column
  • list options
  • number of options
  • shuffle options
  • missing-answer
  • Randomize entries
  • user journey data
  • default: 0 for first execution
  • Display round number
  • Display current score
  • use first active input if both of them are active
  • append to existing results
  • don't write same row twice
  • extract ordered column names
  • fix column order
  • current match results
  • filter guesses
  • Show match results
  • 10 higher
  • results_match_spec.csv for table structure
  • write new results_match.csv used for this match
  • rename column to username
  • unique session identifier with date&time
  • upload dataset
  • display game logo
  • Read logo
  • read default file
  • Welcome message
  • context.workflow.username

Nodes

Extensions

Links