I am trying to create dictionary from a pandas data-frame of the users for the books that the user has read.
| User | Book |
|---|---|
| user1 | book1 |
| user 2 | book1 |
| user1 | book2 |
| user1 | book3 |
| user2 | book3 |
| user2 | book2 |
Expected result:
{
user1: book 1, book2, book3...
user2: book1, book3, book2...
...
}