Tutorial 37: Entropy In Decision Tree Intuition

Поділитися
Вставка
  • Опубліковано 31 січ 2025

КОМЕНТАРІ • 123

  • @shivadumnawar7741
    @shivadumnawar7741 4 роки тому +23

    One of the great teacher in the Machine Learning field. You are my best teacher in ML.Thank you so much sir for spreading your knowledge.

  • @SALESENGLISH2020
    @SALESENGLISH2020 5 років тому +87

    I checked all the codes in your book. Everything works like charm. I can guess that you have mastered Machine Learning by struggling through it. Those who are spoon-fed cannot be half as good as you. Great job! We wish you all the success.

    • @mackjagger602
      @mackjagger602 3 роки тому

      @Nikolas Adrien instablaster =)

    • @nikolasadrien5284
      @nikolasadrien5284 3 роки тому

      @Mack Jagger i really appreciate your reply. I got to the site through google and im waiting for the hacking stuff now.
      Takes quite some time so I will reply here later when my account password hopefully is recovered.

    • @nikolasadrien5284
      @nikolasadrien5284 3 роки тому +1

      @Mack Jagger It worked and I finally got access to my account again. Im so happy:D
      Thank you so much you really help me out !

    • @mackjagger602
      @mackjagger602 3 роки тому

      @Nikolas Adrien You are welcome :)

    • @AjayKumar-id7mb
      @AjayKumar-id7mb 3 роки тому

      @@nikolasadrien5284 gmail reset password

  • @yamika.
    @yamika. 2 роки тому +2

    thank you. we all need teachers like you. god bless you. you're a blessing for us college students who are struggling with offline colleges after the reopening.

  • @mdrashidansari7476
    @mdrashidansari7476 5 років тому +2

    You cleared my all doubts about Entropy..... Excellent Explanation 😍😍😍😍

  • @bhavikdudhrejiya4478
    @bhavikdudhrejiya4478 3 роки тому

    Best channel for Data Science Beginners

  • @rchilumuri
    @rchilumuri 4 роки тому +2

    You are doing an awesome job with our expecting returns. good job Krish, You just nail down the concepts in a line or two thats the way i like it.

  • @aaroncode2634
    @aaroncode2634 5 років тому +10

    This is what I was looking for. Thank you so much for making this video. Eagerly wait for video on information gain. Please keep going 🙏

  • @ayberkctis
    @ayberkctis 3 роки тому +1

    You clearly explain the mathematics of machine learning algorithms! Thank you for your effort.

  • @sandipansarkar9211
    @sandipansarkar9211 4 роки тому +1

    Good explanation Krish.Now my misconceptions about decision trees is dwindling away.Thanks

  • @ABINASHPANDA-be7ug
    @ABINASHPANDA-be7ug 2 роки тому +4

    Hi, there might be calculation mistake in the entropy part. its not 0.78. Can you please mention that in a caption in the video or a description. So that people dont mistaken it in the future. Great video!!

  • @keamogetsethaoge6688
    @keamogetsethaoge6688 5 років тому +1

    Thank you Thank you Thank youuuuu!! After this I am ready for my test tomorrow.... You are boss with these concepts!!.. Please keep making more. I''ll definitely subscribe and share with friends.

  • @cequest9456
    @cequest9456 4 роки тому +4

    You should start explaining from the root node.. Like take entropy of all f1, f2 ,f3 first.. then select the best one as the root node, then calculate entropy for remaining data for f2 and f3, and select next best entropy as the node... and continue the same process

  • @sameerkhnl1
    @sameerkhnl1 3 роки тому +4

    Thank you for a great tutorial. The entropy value is actually 0.97 and not 0.78.

  • @rohitrathodi3
    @rohitrathodi3 2 місяці тому

    I have exam today at noon and was stuck on this concept for a while

  • @abdulkayumshaikh5411
    @abdulkayumshaikh5411 3 роки тому

    Explained in a great way ...Thank you krish

  • @lekhnathojha8537
    @lekhnathojha8537 2 роки тому

    very well understandable your teaching curriculum.

  • @vaddadisairahul2956
    @vaddadisairahul2956 4 роки тому

    in my opinion, calculating entropy is sufficient and we don't require information gain, as in information gain we simply subtract from the entropy of attribute from the entropy of dataset; the entropy of dataset is always constant for a particular dataset.

  • @Lavanya999-p8e
    @Lavanya999-p8e Рік тому

    This is one of the best explanation thankyou somuch sir

  • @aditisrivastava7079
    @aditisrivastava7079 5 років тому +2

    Nice explanation...... I am learning a lot

  • @VivekKumar-nf8fh
    @VivekKumar-nf8fh 5 років тому +2

    Nice explanation.... But looking for deep learning video..Please don't stop DL in-between

  • @funwithzaeem8417
    @funwithzaeem8417 Рік тому

    bro you look like a great teacher

  • @kunaljain-l8l
    @kunaljain-l8l Місяць тому

    crisp explanation .

  • @maximumthefirst
    @maximumthefirst 4 роки тому +4

    Thanks for the video. At 05:48 , how does -3/5log2(3/5)-(2/5log2(2/5)) equal 0.78 ??? I think the correct answer ist 0.971
    Could you explain?

    • @assiaben1220
      @assiaben1220 3 роки тому

      you're right i calculate it in python and i found it = 0.9709505944546686

    • @rahulbagal6741
      @rahulbagal6741 3 роки тому

      yes you are right

    • @shrutipotdar9357
      @shrutipotdar9357 2 роки тому

      can you tell me how to calculate log of 3/5

    • @deepakjoshi4643
      @deepakjoshi4643 3 дні тому

      He said let consider the value will be 0.78 he is just showing how it is done, not showing exact calculation.

  • @AbhishekRana-ye9uw
    @AbhishekRana-ye9uw 3 роки тому +1

    very much helpful sir thank you you are best :)

  • @RahulKumar-ec1dp
    @RahulKumar-ec1dp 3 роки тому

    @2:16 Entropy is "measure of impurity" thats why we tried to decease the entropy

  • @MrBank1717
    @MrBank1717 2 роки тому

    Awesome video.

  • @vishaljhaveri7565
    @vishaljhaveri7565 3 роки тому

    Thank you, Krish sir.

  • @143balug
    @143balug 4 роки тому

    Thank you so much for providing the videos with detail explanations.

  • @vishal56765
    @vishal56765 5 років тому

    Very nicely explain sir. Thanks a lot. Waiting eagerly for next video on information gain.

  • @ambresh009
    @ambresh009 Рік тому

    @krishNaik, I like your videos very much as they are quick reference guides for me to quickly understand something required for interview prep or for any project.
    Just noticed here that, you mentioned Entropy is a measure of purity. But, it is a measure of impurity which makes more sense. The more the value of entropy, more is heterogeneity in the variable.

  • @AromonChannel
    @AromonChannel 3 роки тому

    Definitely subscribe and tell my fellow other programmer to see and subscribe your channel, you are the best explainer i've ever seen!

  • @GhizlaneBOUSKRI
    @GhizlaneBOUSKRI 4 роки тому +2

    I always think it's hard until you convice me how ridiculousely easy it is ..

  • @b.f.skinner4383
    @b.f.skinner4383 3 роки тому

    Great introduction to the topic, thank you

  • @ahmarhussain8720
    @ahmarhussain8720 3 роки тому

    excellent explanation man, thanks

  • @omerahmaad
    @omerahmaad 5 років тому

    Good Video, I think you should add gini impurity in the video to explain the decision tree splits, also what is the difference between entropy and gini impurity. Good Video

  • @marijatosic217
    @marijatosic217 4 роки тому +1

    Great explanation! Thank you :)

  • @louerleseigneur4532
    @louerleseigneur4532 3 роки тому

    Thanks Krish

  • @ankitachaudhari99
    @ankitachaudhari99 3 роки тому

    good explanation

  • @nirajchaudhari5974
    @nirajchaudhari5974 4 роки тому +1

    please upload the video for regression tree also and discuss it in detail manner

  • @hemantsharma7986
    @hemantsharma7986 4 роки тому +5

    Hi Sir, this video is 37th in ML playlist but we don't have any decision tree video before it.

  • @beastjaguar7196
    @beastjaguar7196 Рік тому

    thanku a lot🙏😊

  • @deepakkota6672
    @deepakkota6672 4 роки тому +3

    No doubt you have wonderfully explained, What if we have multiple classes in our target variables with not only binary Yes or No? Like a boy, girl and others?

    • @sauravmukherjeecom
      @sauravmukherjeecom 4 роки тому

      Concept remains same, only the number of choices of split increases. So it is technically more difficult to get the optimal trees using information gain.

  • @sandupaegodage8163
    @sandupaegodage8163 3 роки тому

    GOOD ONE

  • @lemonoji288
    @lemonoji288 3 роки тому

    Thank you, this was very helpful!

  • @subrahmanyamkv8168
    @subrahmanyamkv8168 4 роки тому +1

    As Entropy of pure node is zero..I think Entropy is measure of impurity..lesser the Entropy..more pure the node is

  • @shwetadalal1549
    @shwetadalal1549 3 роки тому

    Nice explanation. But actuallly we dont use this formula while modelling. We just set the parameter of decision tree to either entropy or gini. So when does this formula of entropy really help??

  • @yashmehta8886
    @yashmehta8886 3 роки тому +2

    Can you mathematically explain how you obtained entropy=1 for a completely impure split(yes=3, no=3)?

    • @no-nonsense-here
      @no-nonsense-here 2 роки тому +1

      I think you would have got it by now, this is for those who are looking for the mathematical explanation.
      Entropy (3 yes and 3 no)=
      = -(3/6) log_2 (3/6) - (3/6) log_2 (3/6)
      = -(1/2)(-(1/2)) - (1/2)(-(1/2))
      = 1/2 + 1/2
      = 1

  • @imsutenzuklongkumer3318
    @imsutenzuklongkumer3318 2 місяці тому

    Entropy measures the uncertainty or impurities of the datasets

  • @yogendrashinde473
    @yogendrashinde473 Рік тому +3

    Dear Krish Naik Sir.
    Could you please recheck the calculation. As per my calculation entropy for f2 node where the split is 3|2 is 0.97 and not 0.78 ?
    Kindly correct me if I am wrong.

    • @madhankarthick
      @madhankarthick 6 місяців тому

      = -(0.6 * log[0.6])-(0.4*log[0.4])
      = -(0.6 * -0.74])-(0.4*-1.32)
      = 0.44 + 0.53
      =0.97
      Log is on base 2.

  • @reshaknarayan3944
    @reshaknarayan3944 5 років тому

    Best explanation

  • @saurav0777
    @saurav0777 5 років тому

    Great bro ..thanks for uploading it.

  • @sonamkori8169
    @sonamkori8169 4 роки тому

    Thank you Sir 👍

  • @ashishkumari762
    @ashishkumari762 2 роки тому

    thank you

  • @sohammukherjee837
    @sohammukherjee837 3 роки тому

    Hi Krish, can you please explain the process of calculating probability of a class in a decision tree and whether we can arrive at the probability from feature importance

  • @alastairbowie
    @alastairbowie 3 роки тому

    Nice explanation. Cheers =]

  • @amitmodi7882
    @amitmodi7882 3 роки тому

    Super Awsome!

  • @shubhamnehete8020
    @shubhamnehete8020 3 роки тому

    Sir, here u didn't mentioned that how f3 is in right side and how f2 is in left side node. As u said the attribute having less entropy is selected for split. This is understood but why f2 is on left and f3 os on right?

  • @ankursaxena4942
    @ankursaxena4942 4 роки тому

    Nice Video How to use#Linear_Regression in #Machine_Learning

  • @vijayachokkapu724
    @vijayachokkapu724 4 роки тому +1

    Sir,
    To select an attribute at a node in a decision tree we calculate information Gain which ever is having highest that we select as the best attribute at that node but for an example I am getting all the 4 attribute information gain same.
    When I browsed in net it is saying that if we have all the attribute information gain as same then we have to select the best attribute according to their alphabetical order for example if we have A,B,C,D
    We have to select A first then B,C and D
    Is the procedure is correct or any other explanation can u give please

  • @spurthishetty6834
    @spurthishetty6834 3 роки тому

    Hi Krish,
    Have you explained how decision tree works? because im not finding it

  • @patanjalikumar212
    @patanjalikumar212 4 роки тому

    Could you please create a video on decision tree random forest and other classification algorithm from very scratch which could be helpful for new learner or newbies in data science

  • @lucianoval903
    @lucianoval903 4 роки тому

    Yours videos are very nice, but you really need to improve the quality of your microphone

  • @srujanjayraj9490
    @srujanjayraj9490 5 років тому +1

    waiting for the next video

  • @arindamn4880
    @arindamn4880 2 місяці тому

    I can not find the derivation of the entropy formula anywhere

  • @anandachatterjee2976
    @anandachatterjee2976 4 роки тому

    I tried to purchase the going through the above pasted link but its showing unavailable now, could you please tell me how to get your book?I really need that,I follow your channel frequently whenever I face trouble in understanding any concepts of data science and after watching your videos it gets cleared so please let me know how to purchase your book.

  • @muhammadihsan8689
    @muhammadihsan8689 5 років тому

    Great yaar!!!

  • @mdbelalhossainsanto6523
    @mdbelalhossainsanto6523 10 місяців тому +1

    How did you get 0.78 ?

  • @skvali3810
    @skvali3810 2 роки тому

    i have one question .at root node is the gini are Entropy is high are low..

  • @AK-ws2yw
    @AK-ws2yw 3 роки тому

    In the formula of Entropy what is the significance of log base 2, why not simple log having base 10?

    • @satyajitpaul339
      @satyajitpaul339 3 роки тому

      since its binary split so base 2 is taken.

  • @paragjp
    @paragjp 5 років тому

    hi can you pl add link for Gini Index video ? Also pl let me know in which playlist these videos are ? Thanks

  • @digantaroy1310
    @digantaroy1310 4 роки тому

    Hi Krish,
    Can you please share -Decision tree for Regression?
    Having problem in understanding DT incase of regression

  • @sakshiaggarwal3259
    @sakshiaggarwal3259 3 роки тому

    I think your log calculation is wrong. Calculation as shown at 5:54 in video is giving me result of 0.97 bits

  • @deepalisharma1327
    @deepalisharma1327 2 роки тому

    Can we use same feature for multi level split in the decision tree?

  • @pritomdas6215
    @pritomdas6215 5 років тому +1

    Sir Can you also upload about "Information Gain"?

  • @AbhishekVerma-oe8pk
    @AbhishekVerma-oe8pk 5 років тому

    Brilliant

  • @loganwalker454
    @loganwalker454 3 роки тому

    Krish, I love you so much, more than my girlfriend, zillions like from my side. You always make knotty problems so simple

  • @abhiramikc6883
    @abhiramikc6883 4 роки тому

    if we have very high dimensional data , how do we apply decision tree ?

  • @vinayakrao4754
    @vinayakrao4754 Рік тому

    What do you mean by feature?

  • @swetapatra
    @swetapatra 4 роки тому

    so based on entropy we select the parent node?

  • @PrinuTriesHerBest
    @PrinuTriesHerBest 5 років тому

    I couldn't find any videos for information gain. Could you please upload

  • @harivgl
    @harivgl 4 роки тому

    Did not say how to select the root node?

  • @AmitYadav-ig8yt
    @AmitYadav-ig8yt 5 років тому

    Sir, May you please make a video clip on the Decision tree?

  • @murumathi4307
    @murumathi4307 3 роки тому

    Entropy is thermodynamics concept measure tha energy, why using mechine learning.

  • @MuhammadAwais-hf7cg
    @MuhammadAwais-hf7cg 2 роки тому

    why this entropy in bits? as for normal its about 0.97, and how can i convert my entropy iinto bits

  • @karthikvinnakota1943
    @karthikvinnakota1943 4 роки тому

    What if the class attribute has 3 types of tuples...like Low medium and high...??

    • @rohitborra2507
      @rohitborra2507 4 роки тому +2

      you will split them to 3 nodes.

    • @sauravmukherjeecom
      @sauravmukherjeecom 4 роки тому

      @@rohitborra2507I am sorry but this is not correct. The splitting to the nodes depends on features and not on the classes.
      If there are multiple classes, the concept remains absolutely the same, but instead of 2 variables in the entropy calculation now you have 3. So, the technical difficulty of understanding the right way to form the tree becomes more difficult.

  • @swaruppanda2842
    @swaruppanda2842 5 років тому

    Waiting for Information Gain video

  • @sahilaseeja7686
    @sahilaseeja7686 4 роки тому

    Hello sir, i have a question like how does decision tree works in mixed type dataset i.e it includes bot categorical and numerical data type. Suppose its a regression problem and data set include both data type so how will algorithm deal with categorical data type in this?

    • @sauravmukherjeecom
      @sauravmukherjeecom 4 роки тому

      From documentation of sklearn.
      When there is no correlation between the outputs, a very simple way to solve this kind of problem is to build n independent models, i.e. one for each output, and then to use those models to independently predict each one of the n outputs. However, because it is likely that the output values related to the same input are themselves correlated, an often better way is to build a single model capable of predicting simultaneously all n outputs. First, it requires lower training time since only a single estimator is built. Second, the generalization accuracy of the resulting estimator may often be increased.
      With regard to decision trees, this strategy can readily be used to support multi-output problems. This requires the following changes:
      Store n output values in leaves, instead of 1;
      Use splitting criteria that compute the average reduction across all n outputs.
      ....................................
      If it is still not clear, ping me, I will expain.

    • @sahilaseeja7686
      @sahilaseeja7686 4 роки тому

      @@sauravmukherjeecom thanks for you answer. But there is no need to do these things as decision tree can handle both types of data..

  • @arunkumars3966
    @arunkumars3966 3 роки тому

    how is 0.79 bits when you compute it? someone pls explain

  • @deepaksurya776
    @deepaksurya776 4 роки тому +4

    Entropy value is 0.97 not 0.78

    • @vivekmh4469
      @vivekmh4469 4 роки тому +1

      yes you are crt the entropy value is 0.98

    • @starkmend3444
      @starkmend3444 4 роки тому

      Lee Jon Chapman thx 😁

  • @ankush_in_sync5998
    @ankush_in_sync5998 5 років тому

    Best

  • @shivamd.908
    @shivamd.908 4 роки тому

    lower entropy, higher information gain

  • @muhammadjunaidmajeed1211
    @muhammadjunaidmajeed1211 5 років тому

    how to make fuzzy c4.5 on same data-set?

  • @vigneshnagaraj7137
    @vigneshnagaraj7137 5 років тому

    Waiting for information gain bro

  • @shrikantkulkarni5550
    @shrikantkulkarni5550 4 роки тому +2

    Good explaination however always I observed that you will not explain the meaning of the term on which you made the video and always you will explain things in diplomatic way, please use the simple terms to explain the concepts.

  • @mehdicharife2335
    @mehdicharife2335 Рік тому

    You don't explain the intuition though.

  • @vigneshnagaraj7137
    @vigneshnagaraj7137 5 років тому

    Can you please give the overview of Decision Trees as you have given for Random Forest

  • @movocode
    @movocode 5 місяців тому

    GOD

  • @fatriantobong
    @fatriantobong 8 місяців тому

    why a lot of talks tho... just show the example case

  • @ernestanonde3218
    @ernestanonde3218 2 роки тому

    I SAID I LOVE YOU

  • @memeddk
    @memeddk 2 роки тому +1

    tidak membantu