Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Values(Wind) = {Weak, Strong}
- S = {D4, D5, D6, D10, D14}
- S = [3+, 2—] S_Weak = [3+, 0—] S_Strong = [0+, 2—]
- Entropy(S) = Entropy[3+, 2—]
- = — (2/5).log2 (2/5) — (3/5).log2 (3/5) = 0.970
- Similarly,
- Entropy(S_Weak) = Entropy[3+, 0—] = 0
- Entropy(S_Strong) = Entropy[0+, 2—] = 0
- Information Gain(S, Wind) = Entropy(S) — (3/5).Entropy(S_Weak) — (2/5).Entropy(S_Strong)
- = 0.970 — 0 - 0
- = 0.970
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement