Which marketing channel is worth the money?

Compare weekly ad spend with sales to see which channel moves with sales, using a sample data table.

Also in: Español, Português, Français, Bahasa Indonesia, Русский, العربية, हिन्दी, বাংলা, 日本語, 中文

What this chat does

Find out which marketing channel's spend moves most closely with weekly sales, and get a test to check it.

A marketing lead keeps one row per week: spend on search, social and flyers, and the sales that week.

Asking which channel moves with sales is a quick way to see where money may be working. A correlation is only a clue, so the chat ends with a simple test to run before changing the budget.

How to do it

  1. Load the sample sheet into a table, replacing it if it already exists.
  2. Look at the last few weeks to check the data looks right.
  3. Ask which channel moves most with sales over a recent period.
  4. Plan a small test before moving budget, and compare the results after 4 weeks.

The chat

Sample data: marketing.csv (104 weeks, 2024-12-02 to 2026-11-23)

Recorded from a real run. Prompts and replies are as written; failed attempts and table look-ups are left out. Open a tool call to see what ran. (2026-12-03)

Load https://samples.gotsimplified.com/marketing/marketing.csv into a table called marketing. Replace it if it already exists.

No marketing table exists yet, so there's nothing to replace. I'll load the file into default.marketing.

Tool call · datalake_mutate
action: insert · namespace: default · table_name: marketing · url: https://samples.gotsimplified.com/marketing/marketing.csv

Successfully imported 104 rows into table 'default.marketing'.

  • Namespace: default
  • Table name: marketing
  • Imported rows: 104
  • Format: csv
  • Mode: append
  • Snapshot id: 5975786669951562762
Tool call · datalake_query
DESCRIBE default.marketing
  • Namespace: default
  • Table name: marketing
  • Current snapshot id: 5975786669951562762
  • Total snapshots: 1

Schema

IdNameTypeRequired
1weekdateNo
2search_spendlongNo
3social_spendlongNo
4flyer_spendlongNo
5saleslongNo

Properties

None.

I loaded the CSV into a new table, default.marketing, with 104 rows. I found no existing marketing table in any of your namespaces, so nothing was replaced.

ColumnType
weekdate
search_spendinteger (long)
social_spendinteger (long)
flyer_spendinteger (long)
salesinteger (long)

You didn't name a namespace, so I used default. I didn't set a key or partitioning.

Show me the last 12 weeks, newest first.

Tool call · datalake_query
SELECT * FROM default.marketing ORDER BY week DESC LIMIT 12
weeksearch_spendsocial_spendflyer_spendsales
2026-11-238151803718478
2026-11-161996832457049
2026-11-092014633646503
2026-11-025944582117973
2026-10-266026501048263
2026-10-191482594286456
2026-10-124355082997911
2026-10-056923811218164
2026-09-283485332197177
2026-09-215083272657035
2026-09-142753764506733
2026-09-076895102118467

12 rows.

Here are the last 12 weeks in default.marketing, newest first:

WeekSearch spendSocial spendFlyer spendSales
2026-11-238151803718,478
2026-11-161996832457,049
2026-11-092014633646,503
2026-11-025944582117,973
2026-10-266026501048,263
2026-10-191482594286,456
2026-10-124355082997,911
2026-10-056923811218,164
2026-09-283485332197,177
2026-09-215083272657,035
2026-09-142753764506,733
2026-09-076895102118,467

Over those 12 weeks, how much did we spend on each channel, and which one moves most with sales?

Tool call · datalake_query
SELECT COUNT(*) n, corr(search_spend, sales) r_search, corr(social_spend, sales) r_social, corr(flyer_spend, sales) r_flyer FROM default.marketing
nr_searchr_socialr_flyer
1040.8751217601896280.343755425796107850.0366838762520527

1 row.

Tool call · datalake_query
SELECT COUNT(*) AS n, MIN(week) AS first_week, MAX(week) AS last_week, SUM(search_spend) AS search_total, SUM(social_spend) AS social_total, SUM(flyer_spend) AS flyer_total, SUM(sales) AS sales_total, corr(search_spend, sales) AS r_search, corr(social_spend, sales) AS r_social, corr(flyer_spend, sales) AS r_flyer FROM (SELECT * FROM default.marketing ORDER BY week DESC LIMIT 12) AS last12
nfirst_weeklast_weeksearch_totalsocial_totalflyer_totalsales_totalr_searchr_socialr_flyer
122026-09-072026-11-23550653283288902090.91901908305648220.07812644677938012-0.6011846005435446

1 row.

Search moves most with sales. These figures cover the 12 weeks from 2026-09-07 to 2026-11-23.

ChannelSpend (12 weeks)Share of spendCorrelation with sales (12 weeks)Correlation (all 104 weeks)
Search5,50639.0%0.920.88
Social5,32837.7%0.080.34
Flyer3,28823.3%-0.600.04
Total14,122100%

Sales over the same 12 weeks totalled 90,209.

  • Search: weeks with more search spend tended to have higher sales, and the pattern holds across the full history.
  • Social: there is almost no linear relationship in these 12 weeks, and only a weak positive one over all 104.
  • Flyer: don't read the -0.60 as flyers hurting sales. It comes from only 12 data points and all but disappears over the full history (0.04).

Correlation runs from -1 to 1 and shows what moves together, not what causes what. For example, if search budgets were raised in weeks when demand was already expected to be high, that would also produce a strong correlation. These are same-week, one-channel-at-a-time figures, so they don't account for delayed effects or the other channels' spend. A controlled test that varies search spend would show whether it actually drives sales.

Try a small test: move 1,000 from social to search for the next 4 weeks. Do not change the sheet yet.

I'll run this as a what-if only, with nothing written to the table. First I need to estimate how sales have responded to each channel.

Tool call · datalake_query
SELECT COUNT(*) AS n, AVG(search_spend) AS m_s, AVG(social_spend) AS m_o, AVG(flyer_spend) AS m_f, AVG(sales) AS m_y, var_samp(search_spend) AS v_s, var_samp(social_spend) AS v_o, var_samp(flyer_spend) AS v_f, var_samp(sales) AS v_y, covar_samp(search_spend, social_spend) AS c_so, covar_samp(search_spend, flyer_spend) AS c_sf, covar_samp(social_spend, flyer_spend) AS c_of, covar_samp(search_spend, sales) AS c_sy, covar_samp(social_spend, sales) AS c_oy, covar_samp(flyer_spend, sales) AS c_fy, MIN(search_spend) AS min_s, MAX(search_spend) AS max_s, MIN(social_spend) AS min_o, MAX(social_spend) AS max_o FROM default.marketing
nm_sm_om_fm_yv_sv_ov_fv_yc_soc_sfc_ofc_syc_oyc_fymin_smax_smin_omax_o
104452.9230769230769383.50961538461536263.70192307692317624.12550251.9551904406337725.3979648991620322.21125840181253626.6735436894047.2337565347275421.2001493651987-364.79807692307764219648.922330097174756.780339805875855.24150485437811387753694

1 row.

Tool call · datalake_query
SELECT COUNT(*) AS n, AVG(search_spend) AS m_s, AVG(social_spend) AS m_o, AVG(flyer_spend) AS m_f, AVG(sales) AS m_y, var_samp(search_spend) AS v_s, var_samp(social_spend) AS v_o, var_samp(flyer_spend) AS v_f, covar_samp(search_spend, social_spend) AS c_so, covar_samp(search_spend, flyer_spend) AS c_sf, covar_samp(social_spend, flyer_spend) AS c_of, covar_samp(search_spend, sales) AS c_sy, covar_samp(social_spend, sales) AS c_oy, covar_samp(flyer_spend, sales) AS c_fy FROM (SELECT * FROM default.marketing ORDER BY week DESC LIMIT 12) AS last12
nm_sm_om_fm_yv_sv_ov_fc_soc_sfc_ofc_syc_oyc_fy
12458.8333333333333444.0274.07517.41666666666750239.7878787878922062.72727272727612456.363636363636-6934.363636363633-12665.090909090906-9450.0158344.621212121228920.363636363623-51577.27272727273

1 row.

The estimate is that sales rise by about 1,600 to 2,700 over the 4 weeks, or roughly 5–9%. This is a projection from past data, not a real test result. I changed nothing in the table.

I read this as 1,000 in total, or 250 per week. It can't mean 1,000 every week, because social has never exceeded 694 in a week.

Plan, using the average of the last 12 weeks as the baseline:

Per weekBaselineScenarioChange
Search459709+250
Social444194-250
Flyer2742740
Total spend1,1771,1770

Estimated sales over 4 weeks, against a baseline of about 30,070:

History usedAdded sales per 1 of searchAdded sales per 1 of socialNet gain from the shiftScenario sales
All 104 weeks4.251.53about +2,700about 32,790
Last 12 weeks3.812.20about +1,600about 31,680

These come from a linear regression of sales on all three channels together, which I calculated from the table's summary statistics.

Cautions

  • Cause: the model shows association, so moving budget may not produce this gain.
  • Limits: it assumes each extra unit of search keeps paying off at the same rate. At 709 a week you're within the past range (up to 877), but returns could shrink.
  • Season: it ignores holidays, trends and delayed effects, all of which could matter in December.

If you run it for real

  • Timing: the data ends with the week of November 23, and this week is already under way. The next four full weeks start December 7, 14, 21 and 28.
  • Comparison: if you can, keep some comparable regions or audiences on the old split. A before-and-after comparison over the holidays could easily mistake seasonal change for the effect of the shift.
  • Stop rule: agree in advance what result would make you switch back.

If you meant a different amount or baseline, I can rerun it.

Tools you need

Start with your own data

Sign up free, then connect your AI assistant so it can use these tools.