# \[MiDS23\] Predicting whether a mushroom is poisonous or edible using five variables

**URL:** <https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324>\
**Category:** Staff Picks\
**Tags:** biological-sciences, data-science, graphics-and-visualization, machine-learning, staff-pick, student-leadership-programs, artificial-intelligence\
**Created:** [July 5, 2023, 7:26pm UTC](https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324 "2023-07-05T19:26:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hzoeanna](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/hzoeanna/32/28254_2.png) [@hzoeanna](https://community.wolfram.com/u/hzoeanna)\
**Post date:** [July 5, 2023, 7:26pm UTC](https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324/1 "2023-07-05T19:26:07Z")

</div>

[Open in Wolfram Cloud ↗](https://www.wolframcloud.com/obj/25ef532b-65fc-49c6-aa7c-f7dd2360bbee)

[DOWLOAD-DESKTOP-NOTEBOOK.nb](https://community.wolfram.com/uploads/short-url/9WzpTwlmLb9Aokj8a8Dt1IPPden.nb) (4.75 MB)  
[mushrooms.csv](https://community.wolfram.com/uploads/short-url/3uFLnU8PNX7MtjvOIVMCD7fUB8I.csv) (365 KB)

---

<div class="post-metadata">

**Author:** ![wolframcommunity](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/wolframcommunity/32/8335_2.png) [@wolframcommunity](https://community.wolfram.com/u/wolframcommunity)\
**Post date:** [July 5, 2023, 7:34pm UTC](https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324/2 "2023-07-05T19:34:28Z")

</div>

![news-congrads-kkluyshnik-02-04-19.jpg](https://global.discourse-cdn.com/wolfram/original/3X/6/a/6a310c2d0904616faf4e6e148260c9f29ab9f4eb.jpeg) – you have earned _ **Featured Contributor Badge** _ ![2015-11-02_10-07-11.png](https://global.discourse-cdn.com/wolfram/original/3X/5/0/50e59c9ead62f729e7130d3ea1482555a75602b6.png)  
Your exceptional post has been selected for our editorial column _ **Staff Picks** _ [http://wolfr.am/StaffPicks](http://wolfr.am/StaffPicks) and [Your Profile](http://community.wolfram.com/web/hzoeanna) is now distinguished by a _ **Featured Contributor Badge** _ and is displayed on the [Featured Contributor Board](https://community.wolfram.com/people). Thank you!

---

<div class="post-metadata">

**Author:** ![ghorbani](https://avatars.discourse-cdn.com/v4/letter/g/6a8cbe/32.png) [@ghorbani](https://community.wolfram.com/u/ghorbani)\
**Post date:** [July 6, 2023, 5:25am UTC](https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324/3 "2023-07-06T05:25:00Z")

</div>

An amazing post, Zoe. Congratulation.

Mohammad

---

<div class="post-metadata">

**Author:** ![konczerj](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/konczerj/32/12290_2.png) [@konczerj](https://community.wolfram.com/u/konczerj)\
**Post date:** [July 7, 2023, 3:28pm UTC](https://community.wolfram.com/t/mids23-predicting-whether-a-mushroom-is-poisonous-or-edible-using-five-variables/22324/4 "2023-07-07T15:28:00Z")

</div>

Outstanding post Zoe, I am glad that this nice project has been published!  
I think it motivates and demonstrates essential machine learning and classification concepts very neatly.

However I can’t resist to warn the general public, that – as Zoe pointed out in the first sentences – poisonous mushrooms are often deadly, so be extremely careful even with a high accuracy model.

To take into account of this asymmetry of classes, a natural enhancement might be to tweak the UtilityFunction of the model:

> **[UtilityFunction: Function to be maximized by the decision value—Wolfram...](https://reference.wolfram.com/language/ref/UtilityFunction.html)**
>
> UtilityFunction is an option for Predict, Classify, and related functions that specifies the utility value to assign to each possible pairing of actual and predicted values.

Similar to the examples in Etienne Bernard’s book:

> **[Introduction to Machine Learning](https://www.wolfram.com/language/introduction-machine-learning/classification/)**
>
> Book combines coding examples with explanatory text to show what machine learning is, applications, and how it works. Explore classification, regression, clustering, and deep learning.

Or one can be just more conservative in their mushroom picking practices 🙂
