October 29, 2026

Welcome to Data Stories

Understanding what makes a car fuel-efficient

Can a car’s weight and engine size tell us how much fuel it consumes?

This presentation explores the relationship between vehicle characteristics and fuel efficiency using R and interactive Plotly visualizations.

Created: October 29, 2026

Meet the Dataset

The mtcars dataset is built into R. It contains information about 32 cars from the 1970s.

## Number of cars: 32
## 
## Average fuel efficiency: 20.09 miles per gallon
## 
## Average weight: 3.22 thousand pounds

We will focus on three variables:

  • MPG: Miles per gallon, a measure of fuel efficiency.
  • Weight: Vehicle weight, measured in thousands of pounds.
  • Horsepower: Engine power.

Does Weight Affect Fuel Efficiency?

Try it: Hover over individual points to identify cars and their fuel efficiency. Click the legend to show or hide cylinder groups.

What About Horsepower?

The point sizes represent vehicle weight. Explore the chart to compare cars with different engine power and weights.

Key Findings

## Weight vs MPG correlation: -0.87
## 
## Horsepower vs MPG correlation: -0.78
  • Weight: Heavier cars tend to have lower fuel efficiency.
  • Horsepower: Cars with more horsepower also tend to have lower MPG in this dataset.
  • Exploration matters: Interactive charts help us investigate individual cars instead of relying only on averages.

These are correlations, not proof that weight or horsepower alone causes lower fuel efficiency.

Thank You!

Turning data into stories

This project demonstrates how R Markdown combines narrative, code and visualizations in a single presentation.

Tools used: R · R Markdown · Plotly · mtcars

Created on: October 29, 2026

Explore the charts again and see what you discover!