Graphing and Visualization
Learning Objectives
Students will be able to:
- Create time-series line graphs from sensor data
- Choose appropriate graph types for different questions
- Add reference lines and annotations to highlight important features
- Identify patterns, trends, and anomalies in visualized data
Why Visualize Data?
A picture is worth a thousand numbers.
Raw data tables are hard to interpret. Graphs reveal patterns that are invisible in rows of numbers. Good visualizations help you understand your data and communicate findings to others.
Choosing the Right Graph
Line Graph (Time Series)
Use when: Showing how values change over time
Example: CO2 levels throughout a class period
Key features: X-axis is time, connects points with lines, shows trends
Bar Graph
Use when: Comparing categories or conditions
Example: Average CO2 in different rooms
Key features: Categories on X-axis, height shows value, good for comparisons
Scatter Plot
Use when: Looking for relationships between two variables
Example: CO2 vs. number of people
Key features: Each point is one measurement, shows correlation
Histogram
Use when: Showing distribution of values
Example: How often does CO2 exceed 1000 ppm?
Key features: Bars show frequency of value ranges
Anatomy of a Good Graph
CO2 Levels During Science Class — October 15
Time of Day
Required Elements
- Title: Describes what the graph shows, includes date/location if relevant
- X-axis label: Names the variable and units
- Y-axis label: Names the variable and units
- Scale: Appropriate range that shows the data well
- Reference lines: Thresholds (800 ppm for "good", 1500 ppm for "poor")
- Legend: If multiple data series, explain what each represents
Adding Reference Lines
Reference lines help viewers quickly understand whether values are good, moderate, or concerning.
| Measure | Reference Lines to Add | Color Suggestion |
|---|---|---|
| CO2 | 800 ppm (good threshold), 1500 ppm (poor threshold) | Green for 800, Red for 1500 |
| PM2.5 | 12 μg/m³ (good), 35 μg/m³ (moderate), 55 μg/m³ (unhealthy) | Green, Yellow, Red |
| Outdoor CO2 | ~420 ppm (ambient outdoor level) | Blue dashed line |
Identifying Patterns
Trends
Is the overall direction going up, down, or staying flat? Example: CO2 gradually increasing throughout class.
Cycles
Do values repeat in a pattern? Example: CO2 rises during class, drops during passing period, rises again.
Anomalies
Are there unusual spikes or dips? Example: Sudden PM2.5 spike when someone walked by with food.
Correlations
Do two things change together? Example: More people = higher CO2.
Lag Effects
Does one change follow another with a delay? Example: CO2 drops 5 min after window opens.
Thresholds
How often are reference values exceeded? Example: CO2 above 1000 ppm for 60% of class.
Creating Graphs in Spreadsheets
Step-by-Step (Google Sheets / Excel)
- Select your data: Highlight the columns for X and Y values (e.g., Time and CO2)
- Insert chart: Insert → Chart (Google) or Insert → Chart (Excel)
- Choose chart type: Select Line Chart for time series data
- Add title: Click on "Chart title" and type a descriptive title
- Label axes: Edit axis titles to include variable names and units
- Adjust scale: If needed, manually set min/max values for better visualization
- Add reference lines: Add a new series with constant values for thresholds
Pro Tips
- Start Y-axis at 0 or an appropriate baseline (like 400 ppm for CO2)
- Don't connect points if there are gaps in data
- Use different colors for different conditions (windows open vs. closed)
- Add annotations to mark important events (door opened, class started)
Activity: Graph Your Data
Create at Least Two Graphs
Using your collected data, create the following visualizations:
Graph 1: Time Series
Show how your measured variable changed over the collection period
Graph 2: Comparison
Compare conditions (e.g., windows open vs. closed, or different rooms)
Checklist for Each Graph
- ☐ Descriptive title with date/location
- ☐ Both axes labeled with units
- ☐ Appropriate scale (not too compressed, not too stretched)
- ☐ Reference lines for key thresholds
- ☐ Legend if multiple data series
- ☐ Annotations for important events (optional but helpful)
Common Graphing Mistakes
Avoid These
- Missing title or axis labels
- Y-axis that doesn't start at logical value
- Too many data series making graph cluttered
- Wrong graph type for the data
- Missing units (ppm, μg/m³)
- 3D effects that distort interpretation
Do These Instead
- Clear, specific titles
- Logical axis ranges (0-2000 for CO2)
- Simple, clean design
- Match graph type to question
- Always include units
- Stick to 2D graphs
Key Takeaway
Good graphs transform raw numbers into visual stories. Choose the right graph type for your question, include all essential elements (title, labels, units, reference lines), and look for patterns like trends, cycles, and anomalies. A well-made graph makes your data speak clearly to any viewer.