UAT 106 Statistics and Data Analytics for Technology
Worksheet 4 An endurance model for mission planning
Objective
Check and prepare data, find correlations, build regression models and check residuals before using them for planning
Equipment and materials
- Computer with Python, pandas and matplotlib
- endurance.csv and Anscombe's data
- PX4 SITL log and ulog2csv (if available)
Safety
- Desk and simulation work only; no real flights
Steps
- Check data types and missing values in endurance.csv
- Draw a scatter plot coloured by brand with regression lines
- Plot residuals against payload and against run_order
- Fit a model per brand, compare slopes and judge their practical meaning
- Plot all four Anscombe sets and write one sentence of advice for each
- If a PX4 log is available, convert it with ulog2csv, relate voltage to time and state the limits of simulated data
Record of results
| Data | Intercept b0 (min) | Slope b1 (min/kg) | Slope SE | R² |
|---|---|---|---|---|
| Set or plot | What the plot shows | One sentence of advice |
|---|---|---|
Questions
How much do the slopes of brands A and B differ, and is that large compared with the slope SE? Does it matter in practice to a mission planner?
Does the residual plot against run_order show a trend? If so, what would it say about the test, and why does randomising the flight order matter?
A planner wants endurance at 0.75 kg and at 3 kg. Can this model answer both? Why or why not?
What does Anscombe's data teach about reporting r and R², and which plots should this worksheet attach so readers can trust the model?
Check before you hand in
What to hand in
- Data check notes
- Scatter and residual plots
- Slope table with conclusions
- Advice for the Anscombe data