CPSC 203, 2025 W2
April 7, 2026
Suppose we’d like to understand the bonds between pairs of people in a book!

Given the text from a novel, how can we infer interaction or connections between characters? Discuss this question, and write down your ideas.
________________________________________
________________________________________
________________________________________
________________________________________
The social network graph will have…
Vertices:
Edges:
We could consider every pair of people and check every paragraph for their presence.
OR, we could
"I'm glad," said Anne quickly. "I couldn't really feel proud of keeping head of little boys and girls of just nine or ten. I got up yesterday spelling 'ebullition.' Josie Pye was head and, mind you, she peeped in her book. Mr. Phillips didn't see her—he was looking at Prissy Andrews—but I did. I just swept her a look of freezing scorn and she got as red as a beet and spelled it wrong after all."
Given [[AS, JP, MP], [MP, PA], [AS, JP]],
[AS, JP, MP, PA]?
{(AS,JP):2, (AS,MP):1, (JP,MP):1, (MP,PA):1}?In the PL activity, load socnet_nb.py.