When forecasting rates, ratios, and percentages, Murphet delivers up to 56% lower error than Prophet
Feature | Prophet | Murphet | Advantage |
---|---|---|---|
Likelihood | Gaussian / Student-t | Beta (0-1) or Student-t | ✓ Murphet |
Valid bounds | Manual logistic "cap" | Built-in logit link function | ✓ Murphet |
Changepoints | Hard, piece-wise linear | Smooth logistic transitions | ✓ Murphet |
Residual structure | Assumes independence | Optional AR(1) disturbance | ✓ Murphet |
Heteroscedasticity | None | Automatic adaptation | ✓ Murphet |
Heavy tails | Student-t noise only | Student-t or β-head with φ-scaling | ✓ Murphet |
Holidays & events | Built-in support | Use changepoints (planned for future) | ~ Prophet |
Maturity | Established ecosystem | Newer, focused implementation | ~ Prophet |
Murphet excels with any data naturally bounded between 0 and 1: churn rates, conversion rates, occupancy levels, adoption percentages, and market share metrics.
Click-through rates, add-to-cart rates, checkout conversion, and other e-commerce KPIs that must stay within valid bounds benefit from Murphet's Beta likelihood.
Hotel occupancy forecasting, flight load factors, and rental capacity utilization rates show dramatic accuracy improvements with Murphet's bounded predictions.
Inventory-to-sales ratios, product return rates, and discount penetration rates maintain realistic bounds even in volatile market conditions.
User retention, feature adoption rates, and engagement metrics benefit from Murphet's smooth changepoints during product launches and updates.
Business metrics with strong seasonal patterns and strict physical bounds (like utilization percentages) benefit from Murphet's enhanced seasonal modeling.
While Murphet outperforms Prophet for bounded metrics, there are cases where Prophet remains a better choice:
For bounded metrics like rates and proportions, Murphet's Beta likelihood provides three critical advantages:
Intrinsic bounds preservation
The Beta distribution is naturally bounded between 0 and 1, ensuring predictions never cross impossible thresholds.
Heteroscedastic uncertainty
Variance naturally decreases near boundaries, creating more realistic prediction intervals that respect physical constraints.
Shape flexibility
Beta can model skewed distributions, unlike Gaussian models that assume symmetry around the mean.
# Prophet requires manual "cap" to bound predictions
prophet_df = df.copy()
prophet_df['cap'] = 1.0 # Manual upper bound
prophet_model = Prophet(growth='linear', mcmc_samples=0)
prophet_model.fit(prophet_df)
# Murphet naturally respects bounds with Beta likelihood
murphet_model = fit_churn_model(
t=df['t'],
y=df['y'],
likelihood="beta", # Automatically ensures 0 < predictions < 1
periods=12,
num_harmonics=3
)
Prophet's Sharp Changepoints:
Prophet uses hard changepoints that create unrealistic kinks in forecasts. The model is also memoryless—each residual is independent of previous observations.
f(t) = k·t + m + Σ δⱼ·I(t > sⱼ)·(t - sⱼ)
Where I() is an indicator function causing abrupt slope changes
Murphet's Improvements:
Murphet implements smooth logistic transitions between trend segments and captures autocorrelation with an AR(1) component:
f(t) = k·t + m + Σ δⱼ·σ(γ·(t - sⱼ))·(t - sⱼ) + AR(1)
Where σ() is the sigmoid function for smooth transitions and AR(1) captures pattern persistence
Real-world Impact:
In rigorous Optuna-tuned cross-validation studies, Murphet consistently outperforms Prophet for bounded metrics.
9-month hold-out test:
Murphet RMSE: 0.091 | Prophet RMSE: 0.158
42% error reduction
12-month hold-out test:
Murphet RMSE: 0.050 | Prophet RMSE: 0.114
56% error reduction
Murphet's residuals show significantly lower autocorrelation and reduced Ljung-Box Q statistics, indicating better capture of underlying patterns and more reliable predictions.
If you're already using Prophet for forecasting rates or proportions, transitioning to Murphet is straightforward:
# --- Prophet code ---
from prophet import Prophet
m = Prophet(
changepoint_prior_scale=0.05,
seasonality_prior_scale=10.0,
seasonality_mode='additive',
mcmc_samples=0
)
m.fit(df)
future = m.make_future_dataframe(periods=12)
forecast = m.predict(future)
# --- Equivalent Murphet code ---
from murphet import fit_churn_model
model = fit_churn_model(
t=df['t'], # Numeric index
y=df['y'], # Target values (between 0-1)
likelihood="beta", # For bounded metrics
delta_scale=0.05, # Same as changepoint_prior_scale
season_scale=1.0, # Similar to seasonality_prior_scale/10
periods=12.0, # Yearly seasonality
num_harmonics=3, # Complexity of seasonal pattern
inference="map" # Fast point estimates (like mcmc_samples=0)
)
future_t = np.arange(df['t'].iloc[-1] + 1, df['t'].iloc[-1] + 13)
forecast = model.predict(future_t)
"Prophet is an excellent general-purpose forecasting tool. Murphet is the specialist when your data has natural bounds."
Murphet isn't meant to replace Prophet in every scenario—it's designed to excel in the specific domain of rate and proportion forecasting where physical constraints matter.