Distribuțiile scorurilor prezise
Acum să exersăm folosirea scorurilor predictive posterioare pentru a vedea cât de bine se potrivește modelul nostru Spotify cu datele reale.
Acest exercițiu face parte din cursul
Modelare de regresie bayesiană cu rstanarm
Instrucțiuni pentru exercițiu
- Calculează scorurile prezise posterior pentru
stan_model - Afișează un rezumat al scorurilor de popularitate observate din datele
songs - Compară acest rezumat cu rezumatele replicărilor 1 și 10
Exercițiu interactiv practic
Încearcă acest exercițiu completând acest cod de exemplu.
# Calculate posterior predictive scores
predictions <- ___(stan_model)
# Print a summary of the observed data
summary(songs$___)
# Print a summary of the 1st replication
summary(predictions[___,])
# Print a summary of the 10th replication
summary(predictions[___,])