Methodology and evidentiary limits

What the data measures

Google Trends provides sampled, normalised search interest on a 0 to 100 scale. Low-volume queries can appear as zero. Equal index values across regions need not represent equal search volumes. See Google’s data explanation.

SOS transforms a single SerpAPI comparison response. It does not recover search counts, market share or a population survey estimate. SerpAPI documents the comparison request.

Share calculation

For query ii at observation tt , let xitx_{it} be its returned interest value. The library calculates

sit=100xit∑j=1Kxjt.s_{it} = 100 \frac{x_{it}}{\sum_{j=1}^{K}x_{jt}}.

The denominator contains the KK selected queries. Complete query coverage and a positive total are required at every observed date. A successful 100% sum check establishes arithmetic consistency only. It does not establish measurement validity or identification.

The parser gives extracted_value precedence. Without it, the string <1 is represented by 0.5, an explicit approximation. If the provider supplies both <1 and an extracted zero, zero takes precedence. Missing or malformed values are rejected. Review sensitivity to small values outside this pipeline.

Metric definitions

MetricCalculation and interpretation
avg_shareUnweighted mean of observed shares; each returned interval receives equal weight
Period volatilitySample standard deviation of shares, in percentage points; undefined for one observation
min_share, max_shareObserved minimum and maximum
total_interest, avg_interestSum and mean of index values; not counts of searches
trend_slopeLeast-squares slope of share against observation number, after sorting by date
trend_directionRising if slope exceeds 0.1; falling if below -0.1; stable otherwise, with configurable boundaries
momentumPercentage change in share over the configured number of observations; unavailable lookbacks and zero baselines produce missing values
Rolling volatilityTrailing sample standard deviation over the configured window; unavailable initial deviation is represented by zero
value_maTrailing mean of interest with available observations; added by the pipeline only when the window exceeds 1
z_scoreDeviation from the query’s whole-period mean, divided by its sample standard deviation
is_anomalyAbsolute z-score strictly greater than 2.5; constant and one-observation series are unflagged

A trend’s units are percentage points per observation, not per day or month. For fewer than two observations the slope is zero. The label stable therefore does not prove stability. Trend fitting and z-scores use the whole observed period; they are retrospective, not online detection or forecast validation. No p-values, confidence intervals, serial-correlation correction or seasonal adjustment are computed. Aggregate CSV metrics are rounded to two decimal places.

Concentration

The retained market_concentration Python key contains an HHI-style summary of selected-query shares at the final date:

H=∑i=1Ksit2.H = \sum_{i=1}^{K}s_{it}^{2}.

The implementation retains labels low for H<1500H<1500 , moderate for 1500≤H<25001500\leq H<2500 , and high otherwise. These are legacy descriptive bins, not a competition-policy assessment. With at most five queries, the theoretical minimum is 10000/K≥200010000/K\geq2000 . The low bin is unreachable for a valid supported comparison. A high label cannot establish concentrated market power.

Minimum evidentiary standard

Claim classSupported evidence
Data descriptionSelected-query shares and descriptive summaries, conditional on query construction and retrieval
Conditional model resultDescriptive least-squares trend only; no inferential trend model
Predictive evidenceNot established; there is no held-out forecasting evaluation
Causal evidenceNot established; no intervention or counterfactual estimator
Decision recommendationEvidence-check suggestions only; allocation decisions require external evidence

Do not attach a universal ±5% error margin to these outputs. The library has no retrieval-level uncertainty estimator. A paper’s empirical variability estimate cannot be treated as a confidence interval for every query or dataset.

For a business recommendation, document the observation, credible alternative explanations, decision-relevant additional evidence and the conditions under which the recommendation would change. Review AI narration under the same standard.