Data Preparation
Uploading experiment data for analysis. AB-Labz Workbench supports two upload methods: directly via CSV file or automatically via API.
Data Format
Data for analysis must contain three required columns, at least one metric, and optionally segments for additional analysis.
Required columns:
- Randomization unit:
user_id,user,device_id,device,uid— unique identifier of user/session/device - Experiment group:
variant,var,group— variant name (control,treatment, or others) - Date:
dt,date,created_at,create_at,dttm,event_date,event_dt— event date
Metric columns (minimum 1): One or more columns with measured indicators. Column name = metric name.
Segment columns (optional): Additional columns for data grouping (for example, platform, city, country). Allow analyzing the experiment by different audience slices.
For more details on structure: See the Data Preparation Guide section for a detailed description of how the final table should look. It describes the structure for API, but the format is the same for CSV — just filter data by specific experiment_id.
Example data:
user_id,variant,dt,registration,revenue,session_duration,platform
user_1,control,2024-01-15,0,0,120.5,ios
user_2,control,2024-01-15,1,49.99,340.2,android
user_3,treatment,2024-01-16,1,29.99,180.0,web
user_4,treatment,2024-01-16,0,0,95.3,iosData Requirements
For conversion metrics: Values must be strictly 0 or 1. Where 1 = event occurred, 0 = did not occur.
Important: Conversion measures the fact of performing an action, not the count. If a user performed an event multiple times (for example, 5 purchases), the data still shows 1 (event occurred), not the number of events. Use numeric metrics to count quantities.
For numeric metrics: Any numeric values (integers or decimals). The system will calculate the average value per user in each group.
For ratio metrics: Uploaded as two separate numeric metrics (numerator and denominator). Ratio is created in the analysis interface after upload.
Variants: Variant names are arbitrary, but control is recommended for the control group. The system supports AB tests (2 variants) and ABC+ tests (3+ variants).
Dates: Date format — YYYY-MM-DD (for example, 2024-01-15). Dates are used to determine experiment start and end.
Segments: Arbitrary string variables for analysis by subgroups. For example, platform (ios/android/web), city (Moscow/SPB), country (RU/US/EU). Segments allow checking how the experiment effect differs for different user groups.
Limitation: A segment must not contain more than 10 unique values. If this limit is exceeded, the segment will not be available for filtering in analysis.
Column Recognition
The system automatically recognizes required columns by their names. You can use any of the supported names:
For randomization unit:
user_id— main nameuser— short formdevice_id,device— for device-level experimentsuid— universal identifier
For experiment group:
variant— main name (recommended)var— short formgroup— alternative name
For date:
dt— main namedate— full formcreated_at,create_at— creation timestampdttm— date and timeevent_date,event_dt— event date
The system recognizes columns regardless of case and even if the column name contains additional characters (for example, user_id_hash is recognized as user_id).
Method 1: CSV File Upload
Upload data directly from your computer.
Limits and Restrictions
Format: CSV only (with comma or semicolon as delimiter)
File size: up to 100 MB
Encoding: UTF-8 (recommended) or Windows-1251
Delimiter: comma (,) or semicolon (;) — detected automatically
Upload Process
Navigate to the Data Preparation section. On the "Upload CSV" tab, click "Select" and choose a CSV file from your computer.
After selecting the file:
- File name will be displayed
- "Upload and Analyze" button will activate
Click the upload button. The process begins:
- Upload file to server
- Validate data structure
- Prepare data for analysis
After upload completes, you can run analysis or forecast. The entire process takes from a few seconds to a minute (depending on file size).
Method 2: API Upload
Retrieve data that was previously sent to AB-Labz Workbench via API.
How it works:
- Your system sends (pushes) experiment data to AB-Labz Workbench via API as it accumulates
- When the experiment is complete, you select it from the list of uploaded experiments in the interface
- The system prepares the data, after which you can run analysis or forecast
How to Retrieve Data
Navigate to the Data Preparation section and select the "Get via API" tab.
In the "Experiment ID" dropdown, all experiments whose data was uploaded via API will be displayed. Select the desired experiment from the list.
After selecting the experiment, data will be automatically prepared, and you can run analysis or forecast.
Important: For API upload to work, you need to configure an API key in the API Keys section and set up data sending from your system. Details in the API documentation section.
Data Validation
The system automatically checks:
- Presence of required columns (
user_id,variant,dt) - Correctness of data types
When errors are detected, a message with problem explanation is displayed. Fix the data and retry upload.
Importing Metrics to Catalog
If the data contains metrics that are not in the catalog, the system will offer to import them.
Import modal window:
- List of new metrics with checkboxes
- Auto-detection of type (conversion/numeric)
- Ability to choose which metrics to add
Important: Import to catalog is optional. Data will be analyzed regardless of whether metrics are added to the catalog.
It's recommended to import metrics for documentation and standardization of names in the team.
