In classification, if I take 2 features and color them according to label, I obtain a plot like this, which gives intuition about the effectiveness of my features.

How can I do a similar plot for regression? My aim is to gain (and give, in a paper or presentation) intuition about different features I use as input to a kernel ridge regression.

The only way I can think of is to take one dimension (i.e. one feature/input) and place it into a plot where x = feature, y = label. But I'm not sure if it will make sense. Maybe an ordering in x or y will make it nicer. But still not sure if this is a good idea enough to do. So I'm open to any advice :)

Thanks in advance,


1 Answer 1


Your first guess is correct. The most straightforward and often the best way to depict the relationship in the sample between two variables is to make a scatterplot. Other types of plots can still be useful, especially if it isn't the case that both variables are continuous. For example, if one variable is a count and the other is a discrete ordered variable, a dot plot can work well. If one variable is continuous and the other has a few discrete values, box plots can work well. And so on.

  • $\begingroup$ Thanks! All my variables are continuous by the way. I would appreciate any comments on the axes (x = feature, y = label, or x = feature_1, y = feature_2?). And what about multiple features? Does it make sense to combine them with different colors, or should I do one plot per feature? If it's alright, I will wait for a little while before accepting to encourage other users commenting too :) Thanks again, $\endgroup$
    – jeff
    Jun 5, 2016 at 16:04
  • 1
    $\begingroup$ Plotting one feature against another, with no indication of the dependent variable (DV), can be useful sometimes, although it certainly doesn't tell you anything about relationships with the DV. For plotting feature–DV relationships, I suggest either sticking to one feature per plot, or plotting two features at a time with heatmaps, where each axis has a feature and the color indicates the DV. $\endgroup$ Jun 5, 2016 at 18:41

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.