I have a df as follows:
|User | Date | Items|
|-----|-----------|------|
|x | 2021/03/01| 3 |
|x | 2021/03/09| 5 |
|y | 2021/03/09| 11 |
|z | 2021/03/17| 7 |
I want to summarise this as follows:
|User | Week 1| Week 2| Week 3| Total|
|-----|-------|-------|-------|------|
|x | 3 | 5 | 0 | 8 |
|y | 0 | 11 | 0 | 11 |
|z | 0 | 0 | 7 | 7 |
What is the best way for me to do this?
Apologies if I have the formatting wrong, I'm very new to this - many thanks