The Variable Workshop is your central hub for engineering new variables from your raw data. This powerful feature lets you create transformations that capture real-world marketing behaviors like carryover effects, diminishing returns, and time-shifted impacts—all without writing code.
What is Variable Engineering?
Beyond Raw Data
Raw marketing data often needs transformation to capture:
Carryover effects: TV ads continue influencing sales for weeks
Diminishing returns: First $10K has more impact than next $10K
Time delays: Marketing in Week 1 affects sales in Week 2-3
Interaction effects: TV + Digital together more effective than sum of each
Seasonal adjustments: Normalize for time-of-year patterns
Variable Workshop creates these transformations automatically.
Problem: Linear Models Miss Reality
If you model raw spend:
You're assuming: ❌ Impact is immediate (no carryover) ❌ Returns are constant (no saturation) ❌ Each dollar has same effect (linear)
Reality: ✅ Impact persists over time ✅ Returns diminish with more spend ✅ Relationship is non-linear
With transformations:
Now capturing: ✅ Carryover effects (adstock) ✅ Diminishing returns (saturation) ✅ Realistic marketing response
Result: More accurate attribution, better ROI estimates, actionable insights
Variable Workshop Interface
Three Main Sections
1. Available Variables (Left Panel)
All variables from your uploaded data
Previously created transformations
Search and filter functionality
2. Transformation Builder (Center Panel)
Select transformation type
Preview transformation effect
3. Variable Library (Right Panel)
Edit or delete transformations
Lead/Lag Transformations Shift variables forward or backward in time
Use case: Model delayed effects
Example: TV_Spend_lag1 (last week's TV spend)
Split by Date Create separate variables for different time periods
Use case: Isolate campaign periods or seasonal changes
Example: TV_Spend_Q4_Only
Multiply Variables Combine two variables into one
Use case: Create interaction terms
Example: TV_x_Digital (synergy effect)
Weighted Variables (WGTD) Apply custom weights to variable values
Use case: Emphasize certain periods or adjust for inflation
Adstock (Carryover Effects) Model how marketing impact decays over time
Use case: Capture lasting effects of TV, Radio, Print
Example: TV_Spend_ads60 (60% carryover rate)
Saturation Curves Model diminishing returns using S-shape or concave curves
Use case: Realistic ROI at different spend levels
Example: TV_Spend_ATAN_curve
AVO (Average Value Optimization) Smooth volatile data using moving averages
Use case: Reduce noise in erratic variables
Standardization (STA) Scale variables to mean=0, std=1
Use case: Compare effect sizes across different units
Example: TV_Spend_Standardized
Step 1: Select Base Variable
Choose the variable you want to transform from your uploaded data
Pick from the transformation menu (Lead/Lag, Adstock, Saturation, etc.)
Set transformation settings:
Lag periods (1, 2, 3 weeks)
Adstock rate (30%, 50%, 70%)
Curve parameters (alpha, beta, gamma)
Interactive chart shows:
Original variable (before)
Transformed variable (after)
Step 5: Create Variable
Click "Create" - new variable added to your library
Step 6: Use in Models
Add transformed variable to your models in Model Builder
Preview and Testing
Interactive Preview
Before creating a variable, see:
Visual Comparison:
Line chart: Original vs. Transformed values
Scatter plot: Transformation function shape
Statistics: Mean, range, variance changes
Example Preview:
Test Before Committing
Preview lets you:
Experiment with different parameters
See immediate visual feedback
Understand transformation impact
Avoid creating unusable variables
Iterate until satisfied, then create
You can apply multiple transformations sequentially:
Example: TV with Adstock AND Saturation
Apply adstock: TV_Spend_ads60
Apply saturation: TV_Spend_ads60_ATAN
Order matters:
Usually: Adstock FIRST, then Saturation
Captures: Marketing accumulates over time, then saturates
Creating Complex Variables
Interaction Terms:
Create adstocked TV: TV_ads60
Create adstocked Digital: Digital_ads40
Multiply them: TV_ads60_x_Digital_ads40
Result: Captures synergy between channels with proper carryover
Build Complexity Gradually:
First: Use raw variables in OLS model (baseline)
Then: Add adstock to media channels
Next: Apply saturation curves
Finally: Test interaction terms if needed
Don't over-engineer initially
Name Variables Clearly
Good Naming Convention:
Benefits:
Easy to identify transformations
Keep Track:
Why transformation was applied
Parameter choices and rationale
Which models use which transformations
Use Variable Notes: Each created variable has optional notes field - use it!
Test Impact on Model
After creating transformation:
Add to model in Model Builder
Check coefficient significance (t-stat)
Compare R² with/without transformation
Verify makes business sense
If transformation doesn't improve model, don't use it
Variable Management
Editing Variables
Modify existing transformations:
Click variable in library
Update (replaces in all models using it)
Deleting Variables
Remove unused transformations:
Right-click variable → Delete
Confirmation dialog (can't undo)
Models using it will show warning
Best Practice: Export models before deleting variables
Exporting Variable List
Download Documentation:
Format: Excel or CSV
Use Case: Documentation, sharing with team, reproducibility
Common Use Cases
Use Case 1: TV Campaign with Carryover
Scenario: TV ads continue influencing sales for 4-6 weeks
Solution:
Create TV_Spend_ads60 (60% carryover)
Compare with raw TV spend
Use adstocked version (higher significance)
Use Case 2: Digital Diminishing Returns
Scenario: First $5K in digital has high ROI, next $5K less effective
Solution:
Create Digital_ATAN_concave saturation curve
Test parameters in Curve Testing
Use saturated variable in model
Calculate ROI at different spend levels
Use Case 3: Seasonal Campaign Isolation
Scenario: Holiday campaign Q4 only, want to measure separately
Solution:
Create TV_Spend_Q4_Only (Split by Date)
Use in model alongside TV_Spend_NonQ4
Understand seasonal vs. baseline effectiveness
Use Case 4: Lagged Price Effect
Scenario: Price changes take 2 weeks to affect sales
Solution:
Create Price_lag2 (2-week lag)
If significant, use instead of current price
Better captures actual price-sales relationship
Advanced Features
Create multiple transformations at once:
Select multiple base variables
Apply same transformation type
Configure once, create all
Example: Transform all media channels with 50% adstock in one step
Template Library
Save transformation configurations:
Store commonly used parameter sets
Apply to new variables quickly
Ensure consistency across models
Example Template: "Standard Media Adstock" = 60% rate, applied to TV/Radio/Print
Variable Dependencies
Track relationships:
See which variables are based on others
Understand transformation chains
Avoid circular dependencies
Visual Dependency Graph (coming soon)
Key Takeaways:
🛠️ Variable Workshop = Transformation Hub - create all variable engineering here
📊 Multiple transformation types - time-based, mathematical, marketing-specific
👁️ Preview before creating - see transformations visually before committing
🔗 Combine transformations - adstock + saturation for realistic models
📝 Clear naming - use descriptive names with transformation details
✅ Test in models - verify transformations improve fit and make sense
🎯 Start simple, add complexity - don't over-engineer initially
Next Steps: Explore each transformation type in detail in the following pages!