Recall & Review
beginner
What is resampling in time series data?
Resampling means changing the frequency of time series data, like turning daily data into monthly data or vice versa.
Click to reveal answer
beginner
What does
df.resample('M').mean() do in pandas?It groups the data by month and calculates the average value for each month.
Click to reveal answer
intermediate
Why do we use upsampling in time series?
Upsampling increases the frequency of data, like going from monthly to daily, often filling missing values to keep data consistent.
Click to reveal answer
intermediate
What is the difference between forward fill and backward fill when resampling?
Forward fill fills missing data with the last known value; backward fill uses the next known value.
Click to reveal answer
beginner
How does
resample help in analyzing time series data?It helps by summarizing data at different time scales, making trends and patterns easier to see.
Click to reveal answer
What does the 'W' frequency mean in pandas resampling?
✗ Incorrect
'W' stands for weekly frequency in pandas resampling.
Which method fills missing values with the previous known value during upsampling?
✗ Incorrect
Forward fill uses the last known value to fill missing data.
What happens if you downsample without specifying an aggregation function?
✗ Incorrect
You must specify how to aggregate data when downsampling; otherwise, data may be lost or not aggregated.
Which pandas function is used to change the frequency of time series data?
✗ Incorrect
The resample() function changes the frequency of time series data.
If you want to convert hourly data to daily data by summing values, which code is correct?
✗ Incorrect
Resampling with 'D' changes data to daily frequency; sum() adds hourly values per day.
Explain how you would use resampling to analyze monthly trends from daily sales data.
Think about grouping daily data into months and summarizing.
You got /4 concepts.
Describe the difference between upsampling and downsampling in time series data.
Consider what happens to data points when frequency changes.
You got /4 concepts.