Tinder's Data Science team wants a daily engagement metric for each user. Write a PostgreSQL query that calculates the rolling 7-day average number of swipes per user from Tinder swipe activity.
user_id and swipe date.| Column | Type | Description |
|---|---|---|
| swipe_idPK | INT | Unique swipe event identifier |
| user_id | INT | Tinder user who performed the swipe |
| swiped_at | TIMESTAMP | Timestamp when the swipe occurred |
| swipe_type | VARCHAR(20) | Swipe classification |