I'm trying to understand how various aspects of a movie contribute to its gross revenue. I want to rank a movie's attributes in that sense - the attributes that most strongly determine the revenue are ranked higher.

Let $A_1,\ldots,A_n$ be a list of attributes of a movie and let the possible values of $A_i$ be $a_{i1},a_{i2},\ldots$. Many of these attributes (like primary genre) are categorical and some of them (like rating) are continuous.

Approach 1: Consider $A_1$: I can form groups of movies having the same value of $A_1$, e.g. all movies with $A_1=a_{12}$ form a group. The other attributes in a group can vary freely. I can then calculate the mean of the revenues of all movies within a group, and then take the variance of means of all groups.

This will give me the "variation in average revenue as we change $A_1$ values". If this variation is high, that means changing $A_1$ significantly affects the average revenue - so $A_1$ should be a highly ranked attribute.

Approach 2: Again consider $A_1$: fix the values of all other attributes $A_2,\ldots,A_n$ and look at movies with the same values for $A_2,\ldots,A_n$ but different values of $A_1$. Find the variance in revenues of such movies - call it "$A_1$ variance". The attributes $A_i$ with highest "$A_i$ variance" will be ranked higher.

Approach 3: Train some ML model (not sure which one) with revenue as target variable and attributes as features. Then look at feature importances to get attribute importances.

A few queries:

  1. What assumptions do I need to check for approach 1? e.g. minimum size of a group, distribution of other attribute values within a group, etc.
  2. Are there any potential flaws or gotchas in approaches 1 and 2?
  3. What approach would you prefer out of the three?
  4. What ML model should be used for approach 3? I'm confused because there are plenty of regression models: Linear regression, GB regression, random forest regressor, etc.
  • $\begingroup$ 1) Is it clear that the attributes can be consistently ranked? What if A1 is the number of explosions, A2 the number of kisses and A3 a flag indicating RomCom or Action movie? What is the most important attribute then, A1, A2 or A3? 2) Why don't you try all (ok most) possible approaches and pick the best? $\endgroup$
    – g g
    Commented Feb 11, 2021 at 22:22

1 Answer 1


I think the simple answer to your question is that a model is the best way to incorporate the aspects of Approach 1 and Approach 2 into a unified framework which allows for consistent statements to be made across the attributes. The model could be machine learning, statistical, or Bayesian and could be supervised or unsupervised. You should specify the outcome you want, then pick the best model.


  • I want to rank attributes according to their statistical effect on revenue (generalized linear model)
  • I want to create linear combinations of attributes maximize the variance explained and then look at the contributions to each dimension (principle components)
  • I want to rank attributes according to their importance to some classification exercise (random forest)
  • $\begingroup$ For your first example, can a random forest regressor be used? I'm asking because GLM will have some strong assumptions about the data, won't it? Plus most of the features are categorical $\endgroup$ Commented Feb 16, 2021 at 20:34
  • $\begingroup$ Yes, you can use random forest regression. A GLM has stronger assumptions than the random forest, but those stronger assumptions also allow for stronger statistical statements if you can fit a good model. There are pluses and minuses with a GLM. The categorical nature of the data is not a problem for a GLM. $\endgroup$
    – R Carnell
    Commented Feb 17, 2021 at 1:49
  • $\begingroup$ Just one more thing - could you point me to a more rigorous explanation as to how a model incorporates aspects of approaches 1 and 2 into a unified framework? $\endgroup$ Commented Feb 17, 2021 at 12:05
  • $\begingroup$ Unfortunately, no, I don't have a more rigorous reference that directly compares a modeling method to your specific approaches. I simply tried to understand what you were trying to do in those approaches and relate those in my head to different existing modeling techniques. No one technique covers everything which is why I suggested deciding what measure of attribute rank you care about the most, then pick the model that gives you that. $\endgroup$
    – R Carnell
    Commented Feb 17, 2021 at 13:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.