This node is currently not available in KNIME v4.3 — instead we’re showing this page for **KNIME v4.2**. You can use the version menu in the title bar to permanently switch your preferred version. This will also show the link to the update site.

0 ×

**Market Simulation nodes by Scientific Strategy for KNIME - Community Edition** version **4.0.0.v202007040653** by **Decision Ready, LLC**

Market Simulation is designed to reproduce all of the dynamics of a Market. Hence any observation about a real-world Market can be used to help tune the Market Simulation so that it can make better predictions.

For example, if the Price and Market Share of the Competitor Products in a Market are known, then these measurements can be compared to a Market Simulation model. The Input Parameters of the Market Simulation that define the Vertical Differentiation and Horizontal Differentiation of Products in the Market can then be tuned.

Alternatively, if the precise Quantity Sold of Competitor Products is not known, then the Product Elasticity may be know. Product Elasticity is often calculated for eCommerce Products where a Competitor publishes their Prices but not how much Quantity they've sold. Instead, the Competitor will publish the fact that their Product is Out-of-Stock. When these Out-of-Stock events occur, the user can calculate how much additional Quantity they've sold themselves. This Product Elasticity can then be incorporated into a Tuning Loop.

The Feature Differentiation nodes, Product Generation node, and Simulate Market node can be placed between a 'Tuning Loop Start' node and a 'Tuning Loop End' node. A 'Quantity Error' representing the difference between the actual Quantity Sold and the simulated Quantity Sold can be calculated by the Simulate Market node. The Tuning Loop will then automatically adjust the Input Parameters to minimize the 'Quantity Error' and improve the accuracy of the predictions.

The Tuning Loop may also be used to optimize the sales of Products. For example, a Tuning Loop might be set up to find the Profit Maximizing Price (or Revenue Maximizing Price) of a Product. The Objective Function can be customized to suit the other goals of the user. For example, the user may wish to find a Profit Maximizing Price that does not decrease the amount of Quantity Sold. the Objective Function is set in the 'Tuning Loop End' node.

There are several 'Optimization Methods' available in the Tuning Loop:

● **Parameter Funnel**: (default) The Parameter Funnel algorithm will start by alternatively raising and lowering the Input Parameters by the 'Starting Adjustment Percentage'. For example, if the 'Starting Adjustment Percentage' is 20% then the Search Strategy will try raising and lowering each Input Parameter by 20% (relative to their Maximum Value and Minimum Value). The Input Parameters than improve the Objective Function will be kept. When no more improvement is possible, the Parameter Funnel algorithm will halve the 'Adjustment Percentage' and continue, so that now each Input Parameter will be altered by plus/minus 10%. Halving the 'Adjustment Percentage' is the same as incrementing the 'Tuning Adjustment Depth'. Reducing the 'Adjustment Percentage' from 20% to 10% will increase the 'Adjustment Depth' from 1 to 2. Tuning will stop after a user-defined 'Number of Tuning Adjustment' improvements, or after the Adjustment Depth has reached the 'Maximum Depth of Tuning Adjustments'.

● **Brute Force**: The Brute Force algorithm will test all possible combinations of Input Parameters and return the overall best results. The Brute Force algorithm will initially set the Input Parameter to be equal to the Start Value, then increment by Step Size until the Stop Value is reached.

● **Hill Climb**: The Hill Climb algorithm will initially set each Input Parameter to a random value between the Start Value and the Stop Value. The Hill Climb algorithm will then test each of the direct neighbors by incrementing and decrementing the Input Parameter by the Step Size. The best combination among the each of the neighbors then becomes the new start point for the next iteration. If no neighbor improves the Objective Function the Hill Climb algorithm terminates.

The specific role of the Tuning Loop Start node is to define the set of Input Parameters that will be used to tune the Market Simulation. The user defines these Input Parameters within the Configuration Dialog. Only a very few Input Parameters should be defined to avoid statistical over-fitting. The Tuning Loop Start node then converts these Input Parameters into KNIME Workflow 'Flow Variables'. The Flow Variables then need to override the Configuration Parameters in downstream nodes. This is done by opening the Configuration Dialog of the downstream node, clicking on the 'Flow Variables' tab at the top of the Dialog Box, and then selecting the Configuration Parameter to override. Alternatively, the Flow Variables can be converted into a data table using a KNIME *Variable to Table* node.

**See Also:** 'Parameter Optimization Loop Start' node in the 'KNIME Optimization Extension'.

**More Help:** Examples and sample workflows can be found at the Scientific Strategy website: www.scientificstrategy.com.

- Input Parameter
- The name of the Input Parameter to adjust and tune. These Input Parameters are converted into 'Flow Variables' by the Tuning Loop Start node. The Flow Variables should then be set by the user to override Configuration Parameters in downstream nodes. Alternatively, these Flow Variables can be converted into a data table for use in the downstream Market Simulation workflow. More detail on how this is done is provided in the node description above.
- Start Value
- The initial value of the Input Parameter used to calculate the baseline Objective Function. The Tuning Loop will then alter the Input Parameter Values in an effort to improve (maximize or minimize) the Objective Function.
- Stop Value
- The final value of the Input Parameter used to calculate the baseline Objective Function. For the 'Hill Climb' Optimization Method, the initial value selected for each Input Parameter will be randomly selected somewhere between the Start Value and the Stop Value. The Stop Value is only used for the 'Brute Force' and the 'Hill Climb' Optimization Methods.
- Maximum Value
- The Parameter Funnel algorithm will, at times, increase the value of the Input Parameter towards the Maximum Value. For example, if [Start Value = 100], [Max Value = 200] and [Adjustment Percentage = 20%] then the Tuning Loop will first increase the Input Parameter so that [Value = 120]. That is, so that it is 20% closer to the Maximum Value. In this way, the Input Parameter will eventually asymptote at the Maximum Value [Value = 199.99]. If no Maximum Value is specified [Max Value = 0.0], then the Tuning Loop will exponentially increase the Input Parameter by 20%. If [Max Value = Start Value] then the Input Parameter cannot increase. Recall that the 'Parameter Funnel' Optimization Method will simultaneously increase and decrease the Input Parameter looking for a better Objective Function result.
- Minimum Value
- The Parameter Funnel algorithm will, simultaneously at other times, decrease the value of the Input Parameter towards the Minimum Value. For example, [Start Value = 100], [Min Value = 0] and [Adjustment Percentage = 20%] then the Tuning Loop will first decrease the Input Parameter so that [Value = 80]. That is, so that it is 20% closer to the Minimum Value. In this way, the Input Parameter will eventually asymptote at the Minimum Value [Value = 0.01]. If no Minimum Value is specified [Min Value = 0.0], then the Tuning Loop will asymptote at 0.0 or, if the Start Value is negative [Start Value < 0.0] then exponentially decrease the Input Parameter by 20%. If [Min Value = Start Value] then the Input Parameter cannot decrease. Recall that the 'Parameter Funnel' Optimization Method will simultaneously increase and decrease the Input Parameter looking for a better Objective Function result.
- Step Size
- The incremental size of the step to test neighboring Input Parameters. The Step Size is only used for the 'Brute Force' and the 'Hill Climb' Optimization Methods. For the 'Parameter Funnel' the size of the step will vary according to the 'Adjustment Percentage'.
- Is Integer
- Check to force the Input Parameter to be an integer value, otherwise the Input Parameter will be treated as a real number (double). This setting is only used for the 'Brute Force' and the 'Hill Climb' Optimization Methods.
- Delete Input Parameter Button
- Clicking this button will cause the selected Input Parameter row to be removed from the Tuning Loop Configuration.
- Add Input Parameter Button
- Clicking this button will cause an additional Input Parameter row to be added to the Tuning Loop Configuration.
- Optimization Method
- Select the search strategy Optimization Method for the Market Simulation Tuning Loop. The three available Tuning Loop search strategy Optimization Methods are: Parameter Funnel, Brute Force, and Hill Climb (described above).
- Starting Adjustment Percentage
- The Tuning Loop will start by altering each Input Parameter by plus/minus the 'Starting Adjustment Percentage'. After no more improvements are possible, the Parameter Funnel algorithm will then increase the 'Tuning Depth' by halving the 'Adjustment Percentage'. Each plus-adjustment and each minus-adjustment will be recorded on separate rows in the 'Output Test Results'.
- Maximum Number of Tuning Adjustments
- The maximum number of improvements that have been made to the Objective Function before the Tuning Loop will End. Only actual improvements are counted towards the total. A maximum of 100 improvements is usually reasonable, but up to five thousand improvements are allowed.
- Maximum Depth of Tuning Adjustments
- The maximum 'Adjustment Depth' that will be reached before the Tuning Loop will End. The 'Adjustment Depth' starts at level 1 and increases each time the Parameter Funnel Tuning Algorithm halves the 'Adjustment Percentage'. For example, when the 'Adjustment Percentage' jumps from 20% to 10% the 'Adjustment Depth' will increment from 1 to 2. If there are many opportunities to improve the Objective Function, then the Tuning Loop End will be triggered by quickly reaching the 'Maximum Number of Tuning Adjustments'. If there are few opportunities to improve the Objective Function, then the 'Adjustment Percentage' will decrease and the Tuning Loop End will be triggered by quickly reaching the 'Maximum Depth of Tuning Adjustments'. A maximum depth of 10 is allowed.

**Input Tuning Parameters**: (optional) The set of additional Tuning Parameters to add to the list of Tuning Parameters in the Configuration Dialog. Duplicate Tuning Parameters are not allowed - the same Tuning Parameter cannot be listed in both the Configuration Dialog and the Input Tuning Parameters table. The Input Tuning Parameters should include the following columns:**Parameter**(string): The name of the Input Parameter to adjust and tune. Equivalent to the 'Input Parameter' in the Configuration Dialog. These Input Parameters are converted into 'Flow Variables' by the Tuning Loop Start node. The Flow Variables should then be set by the user to override Configuration Parameters in downstream nodes. Alternatively, these Flow Variables can be converted into a data table for use in the downstream Market Simulation workflow as described above. Duplicate Tuning Parameters are not allowed.**Start**(double): The initial value of the Input Parameter used to calculate the baseline Objective Function. Equivalent to the 'Start Value' in the Configuration Dialog. The Tuning Loop will then alter the Input Parameter Values in an effort to improve (maximize or minimize) the Objective Function.**Stop**(double): (optional) Only used by the 'Brute Force' and the 'Hill Climb' algorithms. Equivalent to the 'Stop Value' in the Configuration Dialog. The final value of the Input Parameter used to calculate the baseline Objective Function. Equivalent to the 'Stop Value' in the Configuration Dialog. For the 'Hill Climb' Optimization Method, the initial value selected for each Input Parameter will be randomly selected somewhere between the Start Value and the Stop Value.**Maximum**(double): (optional) Only used by the 'Parameter Funnel' algorithm. Equivalent to the 'Maximum Value' in the Configuration Dialog. The Parameter Funnel algorithm will, at times, increase the value of the Input Parameter towards the Maximum Value. For example, if [Start = 100], [Maximum = 200] and [Adjustment Percentage = 20%] then the Tuning Loop will first increase the Input Parameter so that [Value = 120]. That is, so that it is 20% closer to the Maximum Value. In this way, the Input Parameter will eventually asymptote at the Maximum Value [Value = 199.99]. If no Maximum Value is specified [Maximum = 0.0 or the Maximum column is missing], then the Tuning Loop will exponentially increase the Input Parameter by 20%. If [Maximum = Start] then the Input Parameter cannot increase.**Minimum**(double): (optional) Only used by the 'Parameter Funnel' algorithm. Equivalent to the 'Minimum Value' in the Configuration Dialog. The Parameter Funnel algorithm will, simultaneously at other times, decrease the value of the Input Parameter towards the Minimum Value. For example, [Start = 100], [Minimum = 0] and [Adjustment Percentage = 20%] then the Tuning Loop will first decrease the Input Parameter so that [Value = 80]. That is, so that it is 20% closer to the Minimum Value. In this way, the Input Parameter will eventually asymptote at the Minimum Value [Value = 0.01]. If no Minimum Value is specified [Minimum = 0.0], then the Tuning Loop will asymptote at 0.0 or, if the Start value is negative [Start < 0.0] then exponentially decrease the Input Parameter by 20%. If [Minimum = Start] then the Input Parameter cannot decrease.**Step**(double): (optional) Only used by the 'Brute Force' and the 'Hill Climb' algorithms. Price of the Product. Equivalent to the 'Step Size' in the Configuration Dialog. The incremental size of the step to test neighboring Input Parameters.**Integer**(boolean): (optional) Only used by the 'Brute Force' and the 'Hill Climb' algorithms. Equivalent to the 'Is Integer' in the Configuration Dialog. If set, forces the Input Parameter to be an integer value, otherwise the Input Parameter will be treated as a real number (double).

**Output Tuning Parameters**: The 'Output Tuning Parameters' is a combination of KNIME Flow Variables (doubles) whose values have been adjusted by the Tuning Loop. Only a very few Output Tuning Parameters should be defined to avoid statistical over-fitting. The user needs to use these Flow Variables to override the Configuration Parameters in downstream nodes. This is done by opening the Configuration Dialog of the downstream node, clicking on the 'Flow Variables' tab at the top of the Dialog Box, and then selecting the Configuration Parameter to override. Alternatively, the Flow Variables can be converted into a data table using a KNIME*Variable to Table*node.

- Random Numbers Generator (100 %) Streamable

- Constant Value Column (43 %) Streamable
- Math Formula (Multi Column) (14 %) Streamable
- Decision Tree Learner (14 %)
- Random Forest Learner (14 %)
- String Manipulation (14 %) Streamable

- CN-161 Tuning Loop Start Node v05 (KNIME Hub)
- CN-162 Tuning Loop End Node v05 (KNIME Hub)
- CS-123 Cola Market 2015 Feature Tuning v05 (KNIME Hub)
- CS-132 SUV Market 2013 Feature Tuning v05 (KNIME Hub)
- MS-161 Stackelberg Leader-Follower Price Competition v05 (KNIME Hub)
- Show all 6 workflows

You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.

Do you have feedback, questions, comments about NodePit, want to support this platform, or want your own nodes or workflows listed here as well? Do you think, the search results could be improved or something is missing? Then please get in touch! Alternatively, you can send us an email to mail@nodepit.com, follow @NodePit on Twitter, or chat on Gitter!

Please note that this is only about NodePit. We do not provide general support for KNIME — please use the KNIME forums instead.