24.07.2016 Views

www.allitebooks.com

Learning%20Data%20Mining%20with%20Python

Learning%20Data%20Mining%20with%20Python

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Re<strong>com</strong>mending Movies Using Affinity Analysis<br />

The result is much more readable (there are still some issues, but we can ignore them<br />

for now):<br />

Rule #1<br />

Rule: If a person re<strong>com</strong>mends Shawshank Redemption, The (1994), Pulp<br />

Fiction (1994), Silence of the Lambs, The (1991), Star Wars (1977),<br />

Twelve Monkeys (1995) they will also re<strong>com</strong>mend Raiders of the Lost Ark<br />

(1981)<br />

- Confidence: 1.000<br />

Rule #2<br />

Rule: If a person re<strong>com</strong>mends Silence of the Lambs, The (1991), Fargo<br />

(1996), Empire Strikes Back, The (1980), Fugitive, The (1993), Star<br />

Wars (1977), Pulp Fiction (1994) they will also re<strong>com</strong>mend Twelve<br />

Monkeys (1995)<br />

- Confidence: 1.000<br />

Rule #3<br />

Rule: If a person re<strong>com</strong>mends Silence of the Lambs, The (1991), Empire<br />

Strikes Back, The (1980), Return of the Jedi (1983), Raiders of the<br />

Lost Ark (1981), Twelve Monkeys (1995) they will also re<strong>com</strong>mend Star<br />

Wars (1977)<br />

- Confidence: 1.000<br />

Rule #4<br />

Rule: If a person re<strong>com</strong>mends Shawshank Redemption, The (1994), Silence<br />

of the Lambs, The (1991), Fargo (1996), Twelve Monkeys (1995), Empire<br />

Strikes Back, The (1980), Star Wars (1977) they will also re<strong>com</strong>mend<br />

Raiders of the Lost Ark (1981)<br />

- Confidence: 1.000<br />

Rule #5<br />

Rule: If a person re<strong>com</strong>mends Shawshank Redemption, The (1994), Toy<br />

Story (1995), Twelve Monkeys (1995), Empire Strikes Back, The (1980),<br />

Fugitive, The (1993), Star Wars (1977) they will also re<strong>com</strong>mend Return<br />

of the Jedi (1983)<br />

- Confidence: 1.000<br />

Evaluation<br />

In a broad sense, we can evaluate the association rules using the same concept as for<br />

classification. We use a test set of data that was not used for training, and evaluate<br />

our discovered rules based on their performance in this test set.<br />

[ 76 ]

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!