In: Statistics and Probability
There are two variables: Favorite film genre and favorite literary genre. Calculate lambda
using literary genre to predict Film Genre.
Literary Genres
mystery sci fi classics
film action 22 42 24
genres comedy 58 52 18
drama 26 30 12
Lambda is defined as an asymmetrical measure of association that is suitable for use with nominal variables.Lambda provides us with an indication of the strength of the relationship between independent and dependent variables. As an asymmetrical measure of association, lambda’s value may vary depending on which variable is considered the dependent variable and which variables are considered the independent variable.
To calculate lambda, you need two numbers: E1 and E2.
The formula for calculating lambda is: Lambda = (E1 – E2) / E1.
Lambda may range in value from 0.0 to 1.0.
Film Genre | Frequency |
Film action | 88 |
Genres comedy | 128 |
Drama | 68 |
Total | 284 |
Let's say you want to guess what the rating of another 284 people would be. Your best guess would be to pick to modal category, which is "Genres comedy" . If you consistently pick "Genres comedy," you will make the fewest number of wrong guesses. Original error=128 right and (284-128)=156 wrong (out of 284 total guesses).
Now, let's say that you are given one additional piece of information. You now know what the frequency of literary genre: mystery,sci fi and classics.
literary genre | ||||
Film Genre | Mystery | Sci fi | Classics | Total |
Film action | 22 | 42 | 24 | 88 |
Genres comedy | 58 | 52 | 18 | 128 |
Drama | 26 | 30 | 12 | 68 |
Total | 106 | 124 | 54 | 284 |
Now, if you had to guess the lierary genre rating, you could qualify your best guess by knowing the literary genre. For each literary genre, you would guess the modal category.
literary genre | N | Modal category | Right Guess | Wrong guess |
Mystery | 106 | Genres comedy | 58 | 48 |
Sci fi | 124 | Genres comedy | 52 | 72 |
Classics | 54 | Film action | 24 | 30 |
Total | 134 | 150 |
The total number of new errors (wrong guesses) is 150
To calculate Lambda, subtract the number of new errors from the number of original errors and divide by the number of original errors. In this case, [(156-150)/156]=0.038
By knowing literary genre, we can reduce the error in predicting Film Genre by 26.3%. This indicates a weak or negligible relationship between literary genre and Film Genre.
As the independent variable is measured on a nominal scale,
there is no direction for the relationship (neither positive nor
negative, just an association).