<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"><channel><title>Behnam Analytics: writing</title><link>https://behnamanalytics.com/writing/</link><description>Healthcare BI, analytics engineering, Power BI, forecasting, and applied AI by Behnam Ebrahimi.</description><language>en-gb</language><item><title>MCP servers for data work</title><link>https://behnamanalytics.com/writing/mcp-servers-for-data-work/</link><guid>https://behnamanalytics.com/writing/mcp-servers-for-data-work/</guid><pubDate>Tue, 29 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>What the Model Context Protocol is, how Claude Code connects to MCP servers, three patterns for analytics teams (read-only database access, documentation lookup and ticketing), and the governance that has to come first.</description></item><item><title>Choosing a Claude model and effort level for analytics work</title><link>https://behnamanalytics.com/writing/choosing-models-and-effort/</link><guid>https://behnamanalytics.com/writing/choosing-models-and-effort/</guid><pubDate>Mon, 28 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>How to pick between Fable, Opus, Sonnet and Haiku and between effort levels for lookups, routine SQL, hard debugging and long builds, and how to make the choice a habit.</description></item><item><title>Reviewing AI-written DAX and SQL</title><link>https://behnamanalytics.com/writing/reviewing-ai-written-dax-and-sql/</link><guid>https://behnamanalytics.com/writing/reviewing-ai-written-dax-and-sql/</guid><pubDate>Sat, 26 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>A review checklist for AI-generated SQL and DAX, with wrong and right pairs for each trap and a small fixture that catches the mistakes before a stakeholder does.</description></item><item><title>Subagents and parallel work in Claude Code</title><link>https://behnamanalytics.com/writing/subagents-and-parallel-work/</link><guid>https://behnamanalytics.com/writing/subagents-and-parallel-work/</guid><pubDate>Fri, 25 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>When to split work across Claude Code subagents, how to brief them, how to stop them racing each other, and how to check the result before anything ships.</description></item><item><title>Prompting for analysts</title><link>https://behnamanalytics.com/writing/prompting-for-analysts/</link><guid>https://behnamanalytics.com/writing/prompting-for-analysts/</guid><pubDate>Thu, 24 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>Prompt patterns that get usable SQL, DAX, and analysis out of a language model, the anti-patterns that waste time, and before-and-after prompts to adapt.</description></item><item><title>Writing CLAUDE.md and AGENTS.md for analytics repos</title><link>https://behnamanalytics.com/writing/writing-claude-md-and-agents-md/</link><guid>https://behnamanalytics.com/writing/writing-claude-md-and-agents-md/</guid><pubDate>Wed, 23 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>What belongs in a project memory file for a coding agent, what doesn't, how Claude Code chooses between CLAUDE.md and AGENTS.md, and two worked examples.</description></item><item><title>A Claude Code workflow for analysts and BI developers</title><link>https://behnamanalytics.com/writing/claude-code-for-data-work/</link><guid>https://behnamanalytics.com/writing/claude-code-for-data-work/</guid><pubDate>Tue, 22 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>Set up the project, keep a short memory file, plan before building, fence the agent into a virtual environment and a branch, and let tests and linters decide when it's done.</description></item><item><title>Forecast accuracy metrics and how to choose them</title><link>https://behnamanalytics.com/writing/forecast-accuracy-metrics/</link><guid>https://behnamanalytics.com/writing/forecast-accuracy-metrics/</guid><pubDate>Mon, 21 Sep 2026 09:00:00 +0000</pubDate><category>Forecasting</category><description>MAE, RMSE, MAPE, sMAPE, MASE, bias, interval coverage and pinball loss, what each one measures, where each misbehaves, and which to put in front of a planning audience.</description></item><item><title>Explaining models to stakeholders</title><link>https://behnamanalytics.com/writing/explaining-models-to-stakeholders/</link><guid>https://behnamanalytics.com/writing/explaining-models-to-stakeholders/</guid><pubDate>Fri, 18 Sep 2026 09:00:00 +0000</pubDate><category>Machine learning</category><description>How to explain a readmission risk model to clinicians and managers. Global and local explanations, permutation importance and partial dependence in scikit-learn, why correlated features mislead, what-if examples, uncertainty, and model cards.</description></item><item><title>Data leakage in healthcare ML, and how to catch it</title><link>https://behnamanalytics.com/writing/data-leakage-in-healthcare-ml/</link><guid>https://behnamanalytics.com/writing/data-leakage-in-healthcare-ml/</guid><pubDate>Thu, 17 Sep 2026 09:00:00 +0000</pubDate><category>Machine learning</category><description>Where leakage hides in health data, from post-discharge fields to time travel in lag features, how to detect it, and two worked examples from a readmission model.</description></item><item><title>Metric definitions as code</title><link>https://behnamanalytics.com/writing/metric-definitions-as-code/</link><guid>https://behnamanalytics.com/writing/metric-definitions-as-code/</guid><pubDate>Wed, 16 Sep 2026 09:00:00 +0000</pubDate><category>Analytics engineering</category><description>Why one organisation ends up with three DNA rates, what a metric definition has to pin down, and how a small YAML file compiled to SQL keeps every report on the same number.</description></item><item><title>DAX for waiting-list KPIs</title><link>https://behnamanalytics.com/writing/dax-waiting-list-kpis/</link><guid>https://behnamanalytics.com/writing/dax-waiting-list-kpis/</guid><pubDate>Tue, 15 Sep 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>DAX patterns for referral-to-treatment reporting, including snapshot and event facts, semi-additive measures, percentage within 18 weeks, median and 92nd percentile waits, and week-on-week comparisons that stay right under any filter.</description></item><item><title>Backtesting forecasts with rolling origins</title><link>https://behnamanalytics.com/writing/backtesting-forecasts-rolling-origin/</link><guid>https://behnamanalytics.com/writing/backtesting-forecasts-rolling-origin/</guid><pubDate>Mon, 14 Sep 2026 09:00:00 +0000</pubDate><category>Forecasting</category><description>Why one train/test split misleads, how rolling-origin evaluation works, expanding versus sliding windows, horizon-aware features, a compact Python loop, and the mistakes that make backtests flatter a model.</description></item><item><title>Claude Code hooks for analytics repos</title><link>https://behnamanalytics.com/writing/claude-code-hooks-for-analytics-repos/</link><guid>https://behnamanalytics.com/writing/claude-code-hooks-for-analytics-repos/</guid><pubDate>Fri, 11 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>How Claude Code hooks work, from events and matchers to exit codes and blocking, and five hooks for a data repository that lint Python and SQL, run fast data tests, protect generated and production files, keep secrets unread and log every command.</description></item><item><title>Calibration before AUC</title><link>https://behnamanalytics.com/writing/calibration-before-auc/</link><guid>https://behnamanalytics.com/writing/calibration-before-auc/</guid><pubDate>Thu, 10 Sep 2026 09:00:00 +0000</pubDate><category>Machine learning</category><description>Why a risk score used for decisions needs probabilities that match reality, and how to check and fix calibration in scikit-learn, with numbers from a readmission model.</description></item><item><title>Data tests that catch real problems</title><link>https://behnamanalytics.com/writing/data-tests-that-catch-real-problems/</link><guid>https://behnamanalytics.com/writing/data-tests-that-catch-real-problems/</guid><pubDate>Wed, 09 Sep 2026 09:00:00 +0000</pubDate><category>Analytics engineering</category><description>Which data tests find the problems that reach production (grain, relationships, codes, freshness, reconciliation, drift), how to set severity, and where to put them.</description></item><item><title>TMDL and version control for Power BI semantic models</title><link>https://behnamanalytics.com/writing/tmdl-version-control-semantic-models/</link><guid>https://behnamanalytics.com/writing/tmdl-version-control-semantic-models/</guid><pubDate>Tue, 08 Sep 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>What TMDL is, how it relates to PBIP and TMSL, what tables, measures and relationships look like as text, and how to review semantic model changes in a Git pull request.</description></item><item><title>Hierarchical forecast reconciliation</title><link>https://behnamanalytics.com/writing/hierarchical-forecast-reconciliation/</link><guid>https://behnamanalytics.com/writing/hierarchical-forecast-reconciliation/</guid><pubDate>Mon, 07 Sep 2026 09:00:00 +0000</pubDate><category>Forecasting</category><description>Forecasting specialty demand that has to add up to the hospital total. Why incoherent forecasts start planning arguments, what bottom-up and top-down get wrong, how MinT reconciliation works, and a backtest in Python.</description></item><item><title>Prediction intervals for planners</title><link>https://behnamanalytics.com/writing/prediction-intervals-for-planners/</link><guid>https://behnamanalytics.com/writing/prediction-intervals-for-planners/</guid><pubDate>Thu, 03 Sep 2026 09:00:00 +0000</pubDate><category>Forecasting</category><description>Why a point forecast isn't a plan, how to build prediction intervals from backtest errors and quantile regression, how to check they hold, and how to choose and present a range for a staffing decision.</description></item><item><title>Evaluating LLM features with a test set</title><link>https://behnamanalytics.com/writing/evaluating-llm-features-with-a-test-set/</link><guid>https://behnamanalytics.com/writing/evaluating-llm-features-with-a-test-set/</guid><pubDate>Wed, 02 Sep 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>How to build a labelled evaluation set before shipping an LLM feature, choose metrics that match the risk, catch regressions when prompts or models change, and keep clinical text governed throughout.</description></item><item><title>Power BI performance starts with VertiPaq</title><link>https://behnamanalytics.com/writing/power-bi-performance-vertipaq/</link><guid>https://behnamanalytics.com/writing/power-bi-performance-vertipaq/</guid><pubDate>Tue, 01 Sep 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>How the VertiPaq engine stores an import model, why cardinality drives size and speed, how to split date-time columns and cut unused ones, and how to use Performance Analyzer, DAX Studio and VertiPaq Analyzer to find the real bottleneck.</description></item><item><title>Skills for repeatable analysis in Claude Code</title><link>https://behnamanalytics.com/writing/skills-for-repeatable-analysis/</link><guid>https://behnamanalytics.com/writing/skills-for-repeatable-analysis/</guid><pubDate>Fri, 28 Aug 2026 09:00:00 +0000</pubDate><category>AI workflows &amp; prompting</category><description>What a Claude Code skill is, how it loads, how to write a description that makes it trigger at the right moment, and two complete skills for analytics work, one that profiles a new table and one that reviews a DAX measure.</description></item><item><title>Logistic regression or gradient boosting for tabular health data</title><link>https://behnamanalytics.com/writing/logistic-regression-vs-gradient-boosting/</link><guid>https://behnamanalytics.com/writing/logistic-regression-vs-gradient-boosting/</guid><pubDate>Thu, 27 Aug 2026 09:00:00 +0000</pubDate><category>Machine learning</category><description>A head-to-head on synthetic readmission data with scikit-learn, comparing AUROC, Brier score, calibration and stability, and a decision guide for choosing between them.</description></item><item><title>Anomaly detection for data feeds</title><link>https://behnamanalytics.com/writing/anomaly-detection-for-data-feeds/</link><guid>https://behnamanalytics.com/writing/anomaly-detection-for-data-feeds/</guid><pubDate>Wed, 26 Aug 2026 09:00:00 +0000</pubDate><category>Analytics engineering</category><description>Catching a broken daily feed before the dashboard does, with day-of-week baselines, robust z-scores, STL residuals, a slow-drift check, freshness and schema checks, and thresholds that don't bury you in alerts.</description></item><item><title>Time intelligence for NHS financial years and rolling periods</title><link>https://behnamanalytics.com/writing/time-intelligence-rolling-periods/</link><guid>https://behnamanalytics.com/writing/time-intelligence-rolling-periods/</guid><pubDate>Tue, 25 Aug 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>A date table that works, financial-year-to-date with an April start, rolling 12 months, same period last year, week-aligned comparisons, incomplete months, and calculation groups to stop the measure count exploding.</description></item><item><title>Funnel plots for comparing units of very different size</title><link>https://behnamanalytics.com/writing/funnel-plots-for-small-numbers/</link><guid>https://behnamanalytics.com/writing/funnel-plots-for-small-numbers/</guid><pubDate>Thu, 20 Aug 2026 09:00:00 +0000</pubDate><category>Data analysis &amp; statistics</category><description>Why league tables of rates put the smallest clinics and practices at both ends, and how a funnel plot with binomial control limits and an overdispersion check fixes it.</description></item><item><title>SQL window functions for patient pathways</title><link>https://behnamanalytics.com/writing/sql-window-functions-for-patient-pathways/</link><guid>https://behnamanalytics.com/writing/sql-window-functions-for-patient-pathways/</guid><pubDate>Wed, 19 Aug 2026 09:00:00 +0000</pubDate><category>Analytics engineering</category><description>ROW_NUMBER, RANK, LAG and window frames applied to first attendances, latest statuses, seven-day totals, continuous spells and 30-day readmissions, with real output and the mistakes that change the answer.</description></item><item><title>A star schema for hospital activity</title><link>https://behnamanalytics.com/writing/star-schema-for-healthcare-activity/</link><guid>https://behnamanalytics.com/writing/star-schema-for-healthcare-activity/</guid><pubDate>Tue, 18 Aug 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>How I'd design a Power BI star schema for admissions, outpatients and waiting lists, from grain decisions and conformed dimensions to role-playing dates, relationship direction and semi-additive snapshots.</description></item><item><title>SPC charts for operational metrics</title><link>https://behnamanalytics.com/writing/spc-charts-for-operational-metrics/</link><guid>https://behnamanalytics.com/writing/spc-charts-for-operational-metrics/</guid><pubDate>Thu, 13 Aug 2026 09:00:00 +0000</pubDate><category>Data analysis &amp; statistics</category><description>How to build an XmR chart for a weekly metric, read the four special-cause rules, recalculate limits after a real change, and stop reacting to RAG noise.</description></item><item><title>CALCULATE and filter context, worked through a waiting list</title><link>https://behnamanalytics.com/writing/calculate-and-filter-context/</link><guid>https://behnamanalytics.com/writing/calculate-and-filter-context/</guid><pubDate>Tue, 11 Aug 2026 09:00:00 +0000</pubDate><category>Power BI, DAX &amp; TMDL</category><description>Row context, filter context, what CALCULATE actually does, KEEPFILTERS, REMOVEFILTERS and ALLEXCEPT, and the iterator mistakes that cost time and give wrong answers, each with a worked example.</description></item></channel></rss>
