Getting started

Build your first model end to end: dataset, variables, period, model, allocator, benchmark.

meryn is a workspace for building marketing mix models (MMM): you upload spend and revenue data, and meryn fits a statistical model that explains how much of your revenue each marketing channel actually drove, then tells you how to reallocate next quarter's budget to get more out of it.

Everything happens on the canvas — a project made of boxes ("nodes") you connect with arrows. Each node does one job: one holds your data, one tells meryn what your columns mean, one trains a model, one turns a trained model into a budget recommendation. This page walks through building one from scratch. Every node is covered in far more depth in the node reference — this page is about the shape of the whole workflow, not every parameter.

1. Create a project

From Projects, click + New Project and give it a name — usually the client or the question you're answering ("Q3 budget reallocation"). The description and the Group field are optional; they only change how the project reads in the list.

The same dialog asks for a data level, and this one can't be changed later:

  • National — one row per period. All three engines are available.
  • By market — one row per period and market. Your file needs a market column and a population column, and only Meridian and PyMC can run on it: Robyn models a single national series, so it isn't offered in a by-market project.

If you're not sure, pick National. To look at the same data both ways, create two projects.

A new project starts private — visible to you and to your team's admins, and to nobody else until you say so. Sharing it is a separate step, and a reversible one: Sharing & publishing.

The Projects page, with + New Project in the top corner
The Projects page, with + New Project in the top corner

You land on an empty canvas:

An empty canvas with the node sidebar open
An empty canvas with the node sidebar open

2. Add a Dataset

Drag a Dataset node onto the canvas and upload a CSV or Excel file (.csv, .xlsx, .xls): one row per date (and per market, in a by-market project), your KPI, and one column of spend per channel. If you don't have a file handy, the dataset modal has a Download example CSV link — it hands you the example that matches your project's level, so you can see the shape meryn expects.

Dragging a Dataset node from the sidebar onto the canvas

Dropping a Dataset opens its configuration right away:

The dataset upload modal
The dataset upload modal

Dataset (and Note) are the only nodes that open on drop. Every other node lands as a blank card first, and its configuration opens when you connect it to its input — the canvas needs to know what feeds a node before it can ask you how to set it up. (EDA has nothing to configure at all: it's created as soon as you connect it.)

meryn reads the file before accepting it: which character separates the columns, which one is the decimal mark, how the dates are written. If any of that needs reformatting to be usable, it shows you what it read — including how it resolved an ambiguous date, since 04/03/2024 is March 4th in one convention and April 3rd in the other — and waits for you to confirm. Nothing is changed silently, and your original file is kept untouched alongside the converted one. A file it genuinely can't use (unreadable encoding, no rows, two columns with the same name) is refused outright, with the reason.

After the upload your canvas has its first node:

The canvas after step 2 — a single configured Dataset node
The canvas after step 2 — a single configured Dataset node

Beyond the file itself there's nothing to configure here. Full detail: Dataset.

3. Connect Variables and map your columns

Drag a Variables node and connect the Dataset's output into it. This is where you tell meryn what each column means — which one is the date, which one is the outcome you're modeling (revenue, conversions...), which ones are paid media, which are organic or contextual factors. Nothing downstream can be built without this step; it's the translation layer between your raw file and every engine's assumptions.

The variables mapping modal, one row per CSV column
The variables mapping modal, one row per CSV column
The canvas after step 3 — Dataset wired into a configured Variables node
The canvas after step 3 — Dataset wired into a configured Variables node

Full detail on every column role: Variables.

4. Connect Period and pick a date range

Drag a Period node off Variables and choose the start and end date to train on. meryn pre-fills the full range your data covers — narrow it if you want to exclude a launch period, a stockout, or anything else that would distort the fit.

The period modal with a date range picker
The period modal with a date range picker
The canvas after step 4 — the date window sits between Variables and everything downstream
The canvas after step 4 — the date window sits between Variables and everything downstream

This step is optional: a model connected straight to Variables trains on the full range. Add a Period when you want a narrower window, or two of them when you want the same data modeled over two different ones.

Full detail: Period.

Optional: look at the data first

An EDA node connects to Variables or Period just like a model does, and instead of training anything it describes what you're about to feed an engine — each series over time, how the channels correlate with each other, how concentrated your spend is. It runs in seconds. It's worth a look before a long training run, especially the first time you use a new file.

Full detail: EDA.

5. Connect a model and configure it

This is the step with real decisions in it. Drag one of the three engine nodes — Robyn, Meridian, or PyMC — off Period and open it. Each engine has its own configuration modal and its own page in this reference; if you're not sure which to start with, Robyn is the fastest to get a first result from and a reasonable default for a first pass. In a by-market project Robyn isn't available, so there the first pass is Meridian or PyMC.

The Robyn configuration modal
The Robyn configuration modal
The canvas after step 5 — a Robyn model hanging off Period, ready to run
The canvas after step 5 — a Robyn model hanging off Period, ready to run

Click Configure, then Run. The node turns from "ready to run" to "running…" — click it and choose View progress & logs to open the progress drawer and watch the live log while it trains.

The run progress drawer showing live logs
The run progress drawer showing live logs

When it finishes, click the node and choose View results to see fit quality, channel contributions over time, response curves, and ROI.

Read the short readiness panel near the top of that page first. Deciding whether a model is good enough to act on otherwise means knowing what a bad number looks like in every column; the panel does that for you and says Ready to use, Use with care or Not ready, listing what's wrong and what to do about it when it isn't green. A fourth verdict, Not enough to judge, means no check could run — which is not a pass. Full detail: Comparing models & choosing a winner.

Full detail on every parameter: Robyn · Meridian · PyMC-Marketing.

6. Connect an allocator

Once a model is trained, drag an Allocator node off it. This is where you turn "here's how each channel performed" into "here's what to spend on each channel next." Pick a scenario — the modal offers the ones your engine supports: for Robyn, Maximize Response or Target Efficiency; for Meridian, Fixed Budget, Flexible Budget (target ROI) or Flexible Budget (target marginal ROI); for PyMC, Fixed Budget or Target Response (minimum budget) — and run it the same way as the model.

The allocator scenario modal
The allocator scenario modal
The canvas after step 6 — the trained model feeding an Allocator
The canvas after step 6 — the trained model feeding an Allocator

Full detail: Budget allocator.

7. Connect a Benchmark and choose a winner

Drag a Benchmark node and connect every model and allocator you want to compare into it — you can run more than one engine on the same data and let the Benchmark line them up side by side. Open Compare to see them together, then set one model (and its allocator) as the winner.

The complete flow — model and allocator both feeding the Benchmark
The complete flow — model and allocator both feeding the Benchmark
The benchmark node's compare and set-winner controls
The benchmark node's compare and set-winner controls

Full detail: Benchmark and Comparing models & choosing a winner.

8. Publish and share

Choosing a winner doesn't show it to anyone by itself — publishing does, and it takes two steps. From the Benchmark node, click Publish for management (it stays disabled until you've set a winner) to publish the flow. Then open the project's Share panel — the Share button in the canvas sidebar — to generate the read-only link you can hand to a client, or to invite specific people as guests. Nobody sees your drafts or the models that didn't win; the published view only ever shows the current winner.

Full detail: Sharing & publishing.

That's the whole loop. Everything past this point in the docs is going deeper on one node or one concept at a time — start with The canvas if you want to understand statuses, connection rules, and what "Run" and "Configure again" actually do before diving into individual nodes.