# Solutions to Just KNIME It!” Challenge 13 - Season 2

**URL:** <https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871>\
**Category:** Just KNIME It!\
**Tags:** justknimeit\
**Created:** [June 21, 2023, 11:31am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871 "2023-06-21T11:31:19Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![alinebessa](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alinebessa/32/33306_2.png) [@alinebessa](https://forum.knime.com/u/alinebessa)\
**Post date:** [June 21, 2023, 11:31am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/1 "2023-06-21T11:31:19Z")

</div>

💥 New Wednesday, new _Just KNIME It!_ challenge! 💥

🔎 This week we focus on XAI (we know you like this topic!) in the context of a real estate problem. 🏡 Are you up for the challenge? 😉

[Here](https://www.knime.com/just-knime-it) is the challenge. Let’s use this thread to post our solutions to it, which should be uploaded to your public [KNIME Hub](https://hub.knime.com/)spaces with tag **JKISeason2-13**.

🆘 **Need help with tags?** To add tag JKISeason2-13 to your workflow, go to the description panel on the right in KNIME Analytics Platform, click the pencil to edit it, and you will see the option for adding tags right there. 🙂 Let us know if you have any problems!

---

<div class="post-metadata">

**Author:** ![AnilKS](https://forum-cdn.knime.com/user_avatar/forum.knime.com/anilks/32/52258_2.png) [@AnilKS](https://forum.knime.com/u/AnilKS)\
**Post date:** [June 21, 2023, 2:30pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/2 "2023-06-21T14:30:46Z")

</div>

challenge header is erroneously seems to be same …

> **[Just KNIME It! | KNIME](https://www.knime.com/just-knime-it)**
>
> Just KNIME It! weekly workflow challenges.

---

<div class="post-metadata">

**Author:** ![rfeigel](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/r/7ea924/32.png) [@rfeigel](https://forum.knime.com/u/rfeigel)\
**Post date:** [June 22, 2023, 2:15am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/3 "2023-06-22T02:15:46Z")

</div>

I’m definitely in the deep end of the pool, but here’s my try. It would be nice in the future if we could get a data dictionary for the column headers. A lot of the abbreviations mean nothing.

> **[JKISeason2-13 – rfeigel](https://hub.knime.com/rfeigel/spaces/Public/latest/JKISeason2-13~DBP9E_T2Z8irqNPl)**
>
> Solutions for data science: find workflows, nodes and components, and collaborate in spaces.

---

<div class="post-metadata">

**Author:** ![Brain](https://forum-cdn.knime.com/user_avatar/forum.knime.com/brain/32/53424_2.png) [@Brain](https://forum.knime.com/u/Brain)\
**Post date:** [June 22, 2023, 4:15pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/4 "2023-06-22T16:15:06Z")

</div>

i agree data science has no sense if you don’t know what you are talking about.

---

<div class="post-metadata">

**Author:** ![aworker](https://forum-cdn.knime.com/user_avatar/forum.knime.com/aworker/32/36421_2.png) [@aworker](https://forum.knime.com/u/aworker)\
**Post date:** [June 23, 2023, 7:22am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/5 "2023-06-23T07:22:34Z")

</div>

Hi @rfeigel

Maybe the following information gathered from different sources can help:

The Boston Housing Dataset is a widely used dataset in machine learning and statistics, particularly in the field of regression analysis. It was first introduced in 1978 by Harrison, D. and Rubinfeld, D.L. as part of a study on housing values in the Boston, Massachusetts area.

The dataset contains information on various factors that are believed to influence housing prices. The goal of the study was to analyze the relationships between these factors and the median value of owner-occupied homes in different suburbs of Boston. The dataset consists of 506 observations and 14 attributes.

The attributes in the original dataset include:

```
CRIM: Per capita crime rate by town
ZN: Proportion of residential land zoned for lots over 25,000 square feet
INDUS: Proportion of non-retail business acres per town
CHAS: Charles River dummy variable (1 if tract bounds river; 0 otherwise)
NOX: Nitric oxides concentration (parts per 10 million)
RM: Average number of rooms per dwelling
AGE: Proportion of owner-occupied units built prior to 1940
DIS: Weighted distances to five Boston employment centers
RAD: Index of accessibility to radial highways
TAX: Full-value property tax rate per $10,000
PTRATIO: Pupil-teacher ratio by town
B: 1000(Bk - 0.63)^2 where Bk is the proportion of Black individuals by town
LSTAT: Percentage of lower status of the population
MEDV: Median value of owner-occupied homes in $1000s (the target variable)

```

The dataset has been used extensively for regression analysis and predictive modeling tasks. It has provided a valuable benchmark for evaluating the performance of different machine learning algorithms, especially those used for predicting housing prices.

Over the years, the Boston Housing Dataset has become a popular choice for teaching and learning purposes due to its relatively small size, well-defined attributes, and real-world applicability. It has served as a foundation for many studies and research papers in the field of data analysis and machine learning.

The Boston Housing Dataset was used in a machine learning and regression competition hosted on Kaggle 5 years ago and complementary information can be found at this link:

> **[The Boston Housing Dataset](https://www.kaggle.com/code/prasadperera/the-boston-housing-dataset)**
>
> Explore and run machine learning code with Kaggle Notebooks | Using data from Boston House Prices

Hope this helps.

Best  
Ael

---

<div class="post-metadata">

**Author:** ![rfeigel](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/r/7ea924/32.png) [@rfeigel](https://forum.knime.com/u/rfeigel)\
**Post date:** [June 23, 2023, 2:26pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/6 "2023-06-23T14:26:47Z")

</div>

@aworker Thanks very much.

---

<div class="post-metadata">

**Author:** ![tomljh](https://forum-cdn.knime.com/user_avatar/forum.knime.com/tomljh/32/67732_2.png) [@tomljh](https://forum.knime.com/u/tomljh)\
**Post date:** [June 24, 2023, 1:01pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/7 "2023-06-24T13:01:56Z")

</div>

Hello everyone, this is my try.

1. Basic visualization (scatter plot and conditional Box plot) is used to analyze the basic relationship between the two features.
2. Referring to [knime examples](https://hub.knime.com/knime/spaces/XAI%20Space/latest/Regression/Custom%20Models/02_SHAP_and_Shapley_Values~E1ofZ6-AEoM_J1xY), based on setting the prediction target (housing price) and establishing a model, we used the SHAP value analysis.

> **[JKISeasor2-13\_tomljh\_ver1 – tomljh](https://hub.knime.com/tomljh/spaces/Public/latest/JKISeason2/JKISeasor2-13_tomljh_ver1~38v0-C3q2_ubz-Pt)**
>
> Chinese Description 中文描述

1. From the perspective of the overall sample, the sample with high crime rate is relatively small, resulting in Outlier on the Box plot. Only when the number of rooms is small, the median of the crime rate is slightly higher (Bar1)  

2. The shap value can analyze more details, and the dependency graph can have three dimensions. Generally, the x-axis is feature 1, the y-axis is the shap value of that feature, and the third dimension represents feature 2 (or target) with color.  
 ![02](https://forum-cdn.knime.com/uploads/default/original/3X/1/a/1a2f04d4b125a951a34ffe6c27a673a00e0e2665.png)

---

<div class="post-metadata">

**Author:** ![MoLa\_Data](https://forum-cdn.knime.com/user_avatar/forum.knime.com/mola_data/32/58742_2.png) [@MoLa\_Data](https://forum.knime.com/u/MoLa_Data)\
**Post date:** [June 25, 2023, 3:10pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/8 "2023-06-25T15:10:16Z")

</div>

Hi Crazy KNIMErs 🤪

Here is my solution this week: [JKISeason2-13 Ángel Molina – KNIME Community Hub](https://hub.knime.com/mola_data/spaces/Public/latest/JKISeason2-13%20%C3%81ngel%20Molina)

Nothing new, I take an [example](https://hub.knime.com/knime/spaces/XAI%20Space/latest/Regression/Custom%20Models/02_SHAP_and_Shapley_Values~E1ofZ6-AEoM_J1xY) in the KNIME HUB as my colleague @tomljh  
I have checked it and it worked perfectly. I have preferred don´t touch anything, it´s perfect for this challenge. I have just added the missing values nodes.

 ![GRAF 2023-06-25 165325](https://forum-cdn.knime.com/uploads/default/original/3X/f/0/f0024e6325b0e3166dedfced41450ccedb14fae9.png)  
 ![WORKFLOW 2023-06-25 164630](https://forum-cdn.knime.com/uploads/default/original/3X/7/e/7e260fb9de5885bbef378af7589294c966a4f1be.png)

As always, here are my [Linkedin](https://www.linkedin.com/in/angel-molina-laguna/) and [Twitter](https://twitter.com/MoLa_data).  
I can´t wait to look 😍 at your solutions KNIMErs!

---

<div class="post-metadata">

**Author:** ![AnilKS](https://forum-cdn.knime.com/user_avatar/forum.knime.com/anilks/32/52258_2.png) [@AnilKS](https://forum.knime.com/u/AnilKS)\
**Post date:** [June 26, 2023, 6:12pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/9 "2023-06-26T18:12:28Z")

</div>

sharing my take on challenge…

> **[Justknimeit-S2C13 – anilks](https://hub.knime.com/anilks/spaces/Just%20Knime%20It%20Challenges/latest/JustKnimeit-S2/Justknimeit-S2C13~tiJzCZVoEJzeHaxx)**
>
> JKISeason2-13

---

<div class="post-metadata">

**Author:** ![Artem](https://forum-cdn.knime.com/user_avatar/forum.knime.com/artem/32/47971_2.png) [@Artem](https://forum.knime.com/u/Artem)\
**Post date:** [June 26, 2023, 6:45pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/10 "2023-06-26T18:45:59Z")

</div>

Hello everyone,

Here is my solution. It is not ingenious at all, I just took the example workflow as many here did and tried to customize it a bit.

> **[JKISeason2-13 – artem](https://hub.knime.com/artem/spaces/Public/latest/JK/JKISeason2-13~okKM4F6jbWlShs1F)**
>
> Solutions for data science: find workflows, nodes and components, and collaborate in spaces.

I also have done some preliminary analysis:

- the correlation coefficient between CRIM and RM is quite low;
- the dispersion for RM is not that big comparing to CRIM;
- as @tomljh suggested I also tried to find out if there is a connection between number of rooms and crime rate — so in general it reduces with increase of number of rooms, while for RM=6 there are the most amount of outliers. This looks strange and I have no explanation for this.

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/4/8/48d93bc7b505bbca10ab841bd1038dcb8d63788f.png)

As for the SHAP values analysis, I tried out 3 models. And it seems that linear regression shows quite well that the connection between CRIM and RM is very weak.

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/0/b/0b4e346accc84a3cc0e18cb8c384492229b0dace.png)

---

<div class="post-metadata">

**Author:** ![HaveF](https://forum-cdn.knime.com/user_avatar/forum.knime.com/havef/32/1124_2.png) [@HaveF](https://forum.knime.com/u/HaveF)\
**Post date:** [June 27, 2023, 6:49am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/11 "2023-06-27T06:49:08Z")

</div>

Hi, KNIMEr, 🥳 🥳 🥳

Here is mine, a more detailed explanation is [here](https://havef.fun/s2c13).

> **[C13 – havef](https://hub.knime.com/havef/spaces/Public/latest/Just_KNIME_It/S2/C13~b-GtqjIULcBZUGjH)**
>
> Solutions for data science: find workflows, nodes and components, and collaborate in spaces.

Best,  
HaveF

---

<div class="post-metadata">

**Author:** ![HeatherPikairos](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/h/a88e4f/32.png) [@HeatherPikairos](https://forum.knime.com/u/HeatherPikairos)\
**Post date:** [June 27, 2023, 8:22am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/12 "2023-06-27T08:22:02Z")

</div>

Hi Everyone 🙂

The same thing for me this week. I have also used the [example](https://hub.knime.com/knime/spaces/XAI%20Space/latest/Regression/Custom%20Models/02_SHAP_and_Shapley_Values~E1ofZ6-AEoM_J1xY) from the hub for my workflow to calculate the Shapley Values and SHAP using the loop nodes.

For the dependence plots, I followed the set-up from the example workflow and therefore plotted the RM column (x-axis) and Shapley\_RM (y-axis) with CRIM as the colour. It appears that the majority of points on the Dependence Plot are black indicating a low crime rate in general. There are a few red points indicating higher crime rates and these appear to be around low to medium RM values, where as at high RM values, all points are black (low CRIM):

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/8/2/8237afc2e6a057f98ec5730979833ffe501c3067.png)

The same can be seen for the SHAP Dependence Plot:

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/6/4/64a5283312e53e2e506572213ca5e68cf2605cb3.png)

As an extra, I also performed Linear Correlation on the original data and created a Heatmap to show the correlation of all pairs of variables. Looking at RM and CRIM on this heatmap, the lilac colour represents a negative correlation:

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/0/4/0437b0ac9b316dd8dd645a04effd4d4096ab70d9.png)

My workflow can be found here:

> **[20230622 Pikairos JustKNIMEIt Season 2 Challenge 13 – heatherpikairos](https://hub.knime.com/heatherpikairos/spaces/Public/latest/Just%20KNIME%20It/Season%202/20230622%20Pikairos%20JustKNIMEIt%20Season%202%20Challenge%2013~CXtKjx6YDSuUFW0A)**
>
> You ara a data scientist working for a real estate company, and heard a rumour that the "average number of rooms per dwelling" (RM) may be connected to the "pe…

Looking forward to seeing the KNIME solution this week to see how it was supposed to be done!

Best wishes  
Heather

---

<div class="post-metadata">

**Author:** ![ersy](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/e/71c47a/32.png) [@ersy](https://forum.knime.com/u/ersy)\
**Post date:** [June 27, 2023, 10:11am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/13 "2023-06-27T10:11:55Z")

</div>

Hi everyone,  
here is my solution:

> **[JKISeason2-13 – ersy](https://hub.knime.com/ersy/spaces/Just%20Knime%20It%20-%20Season%202/latest/JKISeason2-13~Dyr_W-zo8yX-cAyG)**
>
> Challenge 13: Housing

---

<div class="post-metadata">

**Author:** ![alinebessa](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alinebessa/32/33306_2.png) [@alinebessa](https://forum.knime.com/u/alinebessa)\
**Post date:** [June 27, 2023, 1:42pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/14 "2023-06-27T13:42:20Z")

</div>

My bad! So sorry! I fixed it.

---

<div class="post-metadata">

**Author:** ![alinebessa](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alinebessa/32/33306_2.png) [@alinebessa](https://forum.knime.com/u/alinebessa)\
**Post date:** [June 27, 2023, 1:43pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/15 "2023-06-27T13:43:57Z")

</div>

Incredible contribution! Many thanks!

---

<div class="post-metadata">

**Author:** ![alinebessa](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alinebessa/32/33306_2.png) [@alinebessa](https://forum.knime.com/u/alinebessa)\
**Post date:** [June 27, 2023, 1:47pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/16 "2023-06-27T13:47:28Z")

</div>

✨ As always on Tuesdays, here’s our solution to last week’s challenge. ✨

> **[Understanding Crime and Real Estate Connections – knime](https://hub.knime.com/knime/spaces/Just%20KNIME%20It!/latest/Challenge%2013%20-%20Understanding%20Crime%20and%20Real%20Estate%20Connections~_WUx673m-H2jzQWL)**
>
> Level: Medium Description: You ara a data scientist working for a real estate company, and heard a rumour that the "average number of rooms per dwelling" (RM) …

A different contribution by my colleague Keerthan to this XAI problem! 🔎

---

<div class="post-metadata">

**Author:** ![alinebessa](https://forum-cdn.knime.com/user_avatar/forum.knime.com/alinebessa/32/33306_2.png) [@alinebessa](https://forum.knime.com/u/alinebessa)\
**Post date:** [June 27, 2023, 3:10pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/17 "2023-06-27T15:10:09Z")

</div>

🔥 Also, if you’re interested in XAI, do check our new book on the subject!

We talk more about it here: [https://twitter.com/paolotamag/status/1673623143020220416?s=20](https://twitter.com/paolotamag/status/1673623143020220416?s=20)

---

<div class="post-metadata">

**Author:** ![tomljh](https://forum-cdn.knime.com/user_avatar/forum.knime.com/tomljh/32/67732_2.png) [@tomljh](https://forum.knime.com/u/tomljh)\
**Post date:** [June 27, 2023, 11:18pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/18 "2023-06-27T23:18:31Z")

</div>

A very timely book, thank you very much! 😍

---

<div class="post-metadata">

**Author:** ![elimisael](https://forum-cdn.knime.com/user_avatar/forum.knime.com/elimisael/32/63413_2.png) [@elimisael](https://forum.knime.com/u/elimisael)\
**Post date:** [June 30, 2023, 12:09am UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/19 "2023-06-30T00:09:53Z")

</div>

A lot late but here is my solution: [JKISeason2-13 – KNIME Community Hub](https://hub.knime.com/elimisael/spaces/Public/latest/Just%20Knime%20It/Season%2002/JKISeason2-13/JKISeason2-13)

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/2/9/2939ebb6cc2968575f3283bd361404e780da684e.png)

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/0/f/0f1feca767f9e4bcef1e21be316691392d663e6a.png)

---

<div class="post-metadata">

**Author:** ![l6fader](https://forum-cdn.knime.com/user_avatar/forum.knime.com/l6fader/32/53149_2.png) [@l6fader](https://forum.knime.com/u/l6fader)\
**Post date:** [July 1, 2023, 8:52pm UTC](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871/20 "2023-07-01T20:52:04Z")

</div>

Hey All -  
I didnt really enjoy this challenge, mostly because the topic was super tough for me and I didnt actualy build anything, but saw it through to learn something new. I easily followed the hint, borrowed the SHAP value WF from the Hub and modified it to crunch the data. No problem.

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/7/a/7a93188ef9e520cd06718882befb06526a3c09a4.png)

My issue was that i didnt understand what i was doing and could not interpret the output. The real hint came when i read the solution today… after completing Challenge 14! For the most part, i didnt know what the columns meant and so without any context, i just didnt know how to work through the problem. Worse yet, probably because of the version i am using the solution does not import properly for me:

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/4/6/462dfb15ff4485afadca955c16c5e9b06ada8398.png)

But the solution mentions median value of the house in the final line, so i looked back at the columns and found “MEDV”. Eureka! Now i knew what i should predict and then i could look at RM and CRIM the way it is done in the hint. Here is the modified workflow:

> **[JKISeason2-13 – l6fader](https://hub.knime.com/l6fader/spaces/Public/latest/JKISeason2-13_LF~20xdzov1SI5O3OWY)**
>
> Solutions for data science: find workflows, nodes and components, and collaborate in spaces.

here is an example of the dependency plot:

 ![image](https://forum-cdn.knime.com/uploads/default/original/3X/c/3/c35a93bc306855c1aefdc17b1a11f5fbf7bb7c48.png)  
But now what - I had to do some reading to find out what these plots mean. (this is probably the page that got me over the hump: [Explaining Machine Learning Models: A Non-Technical Guide to Interpreting SHAP Analyses](https://www.aidancooper.co.uk/a-non-technical-guide-to-interpreting-shap-analyses/)). I had never heard of XAI or SHAP values. The way i interpret this plot now is that when RM is below 7, RM as a feature has a weak negative impact on the predicted median value of the house. Above 7, there is a strong positive correlation to median house value.

Thanks for this challenge - it was unpleasant and i am still confused, but it forced me out of my comfort zone, which is where i like to be.  
L

[Next page](https://forum.knime.com/t/solutions-to-just-knime-it-challenge-13-season-2/69871.md?page=2)
