Log-Likelihood- Analyttica Function Series

Analyttica Datalab
2 min readFeb 11, 2019

--

To understand “Log Likelihood”, you first need to understand what “Likelihood” is.

Likelihood Ratio test (often termed as LR test) is a test to compare two models, concentrating on the improvement with respect to likelihood value. If we keep on adding predictor variables to a linear model, R-square will improve. This holds true for model likelihood value as well. But, the objective is to check if the improvement in likelihood is good enough or not!

Suppose, we have a data set with two variables, X and Y. You have fitted a regression equation between the two and got estimates or coefficients. Now, the likelihood is a measure that tells you how likely is that you will get a dataset like what you have, given the regression equation.

So, higher the value of likelihood, better is the fit of the model. Actually, all computer algorithms for fitting any regression models are based on maximizing the likelihood value. This estimation is known as “Maximum Likelihood Estimation” or MLE.

Hence once a regression model is fit, we may like to measure the likelihood of the estimates, for which we look at the log of the likelihood value and call it Log Likelihood.

Application & Interpretation:

Log Likelihood value is a measure of goodness of fit for any model. Higher the value, better is the model.

We should remember that Log Likelihood can lie between -Inf to +Inf. Hence, the absolute look at the value cannot give any indication. We can only compare the Log Likelihood values between multiple models.

Input:

To run the Log Likelihood function in Analyttica TreasureHunt, you should select the target variable and one or many independent variables (s). Also, you should select a ‘Family’ of the target variable depending on its distribution.

Output:

The function builds a model to fit independent variables to dependent variables and shows the Log Likelihood value.

--

--

Analyttica Datalab

Analyttica Datalab (www.analyttica.com) is a contextual Data Science (DS) & Machine Learning (ML) Platform Company.