liveBook · Manning

Trend

As explained in Effective Data Analysis

A trend is a sustained pattern of change in a variable across an ordered period.

A trend is a sustained pattern of change in a variable across an ordered period. Analysts use trends to describe data, develop metrics, size opportunities, and support stakeholder decisions without manipulating a test condition. section 3.2.1

Useful descriptive treatments include:

  • Plot observations over time to reveal overall movement and potential changes in the variable. section 3.2.1
  • Aggregate observations by month and compare totals, means, or medians when a daily series is too detailed. section 3.2.1
  • Choose descriptive statistics carefully after exploring the dataset and considering what omitted measures cannot show. section 3.2.1
rats = rats.reset_index()
rats["day"] = pd.to_datetime(rats["day"], format="%m/%d/%y")   #1

rats_group = rats.groupby(pd.Grouper(key="day", axis=0, freq="ME")).agg(
    ["sum", "mean", "median"]
)   #2

rats_group.columns = rats_group.columns.get_level_values(1)  #3

plt.plot(rats_group["sum"])   #4
plt.xlabel("Month (Starting 1/1/2018)")
plt.ylabel("# of Rat Sightings")

This example groups rat sightings by month and plots monthly sums, providing a practical view of an aggregate trend. section 3.2.1

How Effective Data Analysis covers it

How deep it goes
Defines trends descriptively and demonstrates daily/monthly plotting plus mean and median comparison, without establishing causality.
Examples
Uses daily and monthly New York City rat-sighting plots, including totals, means, and medians.
What you can do after
Evaluate trends with time-series plots and descriptive summaries while communicating interpretation limits to stakeholders.
How it connects
Connects trends with descriptive statistics, time series, observational research, and inferential statistics.

Also explained in

Compare how 4 books explain trend →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Effective Data Analysis. The section links point to the parts of the book it draws on.