Interview prep
23 data visualization interview questions, with answers.
Data visualization interview questions with answers: choosing the right chart, honest design, matplotlib, seaborn and plotly, and the plots that matter when you build and evaluate models.
Visualization questions appear in data analyst, data scientist and ML engineer interviews, often as a chart to critique or a question about how you'd show a result to a manager. Interviewers want judgement: the right chart for the question, an honest scale, and a clear takeaway.
For tool questions, show you know when to use each library, not every argument.
These 23 questions are free. SchoolWhool's Foundations of AI course places 650+ interview questions right after the lessons they test, with a mock interview with Gaurav. See also the machine learning interview questions.
Choosing the right chart
How do you choose a chart type?
What's the difference between a bar chart and a histogram?
When do you use a box plot, a violin plot or a histogram?
Why are pie charts criticised, and when are they fine?
How do you show the relationship between two variables with many thousands of points?
How do you visualise a correlation matrix?
How do you visualise high-dimensional data?
Honest, clear design
What makes a chart misleading?
When is it fine for the y-axis not to start at zero?
How do you choose colours?
What is chart junk, and what is the data-ink ratio?
How do you design a chart for a non-technical audience?
How do you show uncertainty?
Tools: matplotlib, seaborn and plotly
What's the difference between a Figure and an Axes in matplotlib?
fig, ax = plt.subplots() then ax.plot(...), is clearer than the implicit plt. state machine, especially with several subplots.When would you use matplotlib, seaborn or plotly?
hue and faceting built in. Plotly produces interactive HTML with hover and zoom and powers Dash dashboards. Choose by audience and medium.How do you make small multiples?
plt.subplots(nrows, ncols, sharex=True, sharey=True) in matplotlib, relplot or catplot with col= and row= in seaborn, or facet_col in plotly. Shared axes keep comparisons between panels honest.How do you save a figure for a report or slides?
fig.savefig('chart.png', dpi=200, bbox_inches='tight'), or SVG or PDF for sharp vector graphics. Set the figure size in inches before plotting, so fonts come out at a readable size rather than being scaled afterwards.What makes a good time-series chart?
Visualization for machine learning
Which plots do you make during exploratory analysis before modelling?
How do you visualise a classifier's performance?
ConfusionMatrixDisplay, RocCurveDisplay and PrecisionRecallDisplay draw them from a fitted model.How do you visualise a regression model's errors?
What does a learning curve show?
How do you show feature importance or feature effects?
Keep preparing
26 pandas interview questions
pandas interview questions on indexing, cleaning, groupby, merges, reshaping and performance, including the warnings and silent bugs interviewers love to ask about.
Interview prep28 scikit-learn interview questions
The scikit-learn questions interviewers actually ask: the estimator API, pipelines and leakage, cross-validation, tuning, and the practical traps that separate people who've used it from people who've read about it.
ArticleAccuracy is lying to you: baselines, imbalance, precision and recall
Why a model that's right 89% of the time can be almost useless, and the three questions to ask before you trust any accuracy score.
Interview prep26 probability interview questions
Probability interview questions for data science and quant roles, with worked answers: conditional probability and Bayes, distributions, expectation, the classic puzzles, and where probability shows up in machine learning.
ArticleMisleading statistics: 10 examples and how to spot each one
Misleading statistics use true numbers to suggest false conclusions. See 10 examples, from truncated axes to Simpson's paradox, and how to spot each one.
ArticleMachine learning interview questions: how to prepare, with worked answers
Machine learning interview questions with worked answers: splits, leakage, precision and recall, baselines, gradient descent and regularisation, in Python.
First Principles, the SchoolWhool newsletter
One machine learning idea, explained properly, every week.
The intuition, the common mistake, and a five-minute way to try it yourself. Written by Gaurav.
Learn it properly, then the interview is the easy part.
Foundations of AI teaches data visualization and the rest of machine learning from first principles, with notebooks that check your work.