IniziaInizia gratis

Pick a winner based on log-likelihood

In this exercise, you will practice using log-likelihood to choose a model with the best fit.

GARCH models use the maximum likelihood method to estimate parameters. In general, the bigger the log-likelihood, the better the model since it implies a bigger probability of having observed the data you got.

Two GARCH models with different distribution assumptions have been defined and fitted with the S&P 500 return data. The normal distribution GARCH is saved in normal_result, and the skewed Student's t-distribution GARCH is saved in skewt_result.

Questo esercizio fa parte del corso

GARCH Models in Python

Visualizza il corso

Esercizio pratico interattivo

Prova a risolvere questo esercizio completando il codice di esempio.

# Print normal GARCH model summary
print(____.____())
# Print skewed GARCH model summary
print(____.____())

# Print the log-likelihood of normal GARCH
print('Log-likelihood of normal GARCH :', ____.____)
# Print the log-likelihood of skewt GARCH
print('Log-likelihood of skewt GARCH :', ____.____)
Modifica ed esegui il codice