From c6eaa2a454929b59ca81f47321bc72c5a5a8a2fd Mon Sep 17 00:00:00 2001 From: Simon Koch-Sultan Date: Mon, 16 Nov 2026 03:56:45 -0500 Subject: [PATCH 1/2] [DOCS] Warn that virtual columns have limited support MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Adds a warning to the Virtual Columns section of docs/user_guide/triangle.ipynb. Estimators such as Development and Chainladder do not evaluate virtual columns, so their results for a virtual column are all NaN, with no warning. The link_ratio and age_to_age properties apply the column's expression to the link ratios of the other columns, which matches the column's own link ratios for a quotient such as PaidLossRatio but not for a difference of two columns. Selecting the column first returns an ordinary Triangle. Refs #1607. Developed with an AI assistant (Árbol, running Muse). --- docs/user_guide/triangle.ipynb | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/user_guide/triangle.ipynb b/docs/user_guide/triangle.ipynb index e20eaab07..13163c671 100644 --- a/docs/user_guide/triangle.ipynb +++ b/docs/user_guide/triangle.ipynb @@ -3206,6 +3206,23 @@ "clrd[[\"CumPaidLoss\", \"PaidLossRatio\"]].sum()[\"PaidLossRatio\"]" ] }, + { + "cell_type": "markdown", + "id": "triangle-virtual-col-limits", + "metadata": {}, + "source": [ + "```{warning}\n", + "Virtual columns have limited support. Estimators such as `Development` and\n", + "`Chainladder` do not evaluate them, so their results for a virtual column are\n", + "all NaN, with no warning. The `link_ratio` and `age_to_age` properties apply\n", + "the column's expression to the link ratios of the other columns. The result matches\n", + "the column's own link ratios for a quotient such as `PaidLossRatio`, but not in\n", + "general, for example for a difference of two columns. Select a virtual column\n", + "first, for example `clrd.sum()[\"PaidLossRatio\"]`, to get an ordinary Triangle\n", + "that these properties and estimators handle correctly.\n", + "```" + ] + }, { "cell_type": "markdown", "id": "eaa8edfc", From ba76b242756051a79d96a65e798832b2c1dd07ec Mon Sep 17 00:00:00 2001 From: Simon Koch-Sultan Date: Mon, 16 Nov 2026 20:11:40 +0000 Subject: [PATCH 2/2] [DOCS] Keep the virtual-column warning to its first two sentences MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The warning now says only that estimators such as Development and Chainladder do not evaluate virtual columns and return all-NaN results for them. The link-ratio caveat and the select-first tip are dropped, as asked in review; #1607 still covers the link-ratio behavior. Developed with an AI assistant (Árbol, running Muse). --- docs/user_guide/triangle.ipynb | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/docs/user_guide/triangle.ipynb b/docs/user_guide/triangle.ipynb index 13163c671..8dd0d2f87 100644 --- a/docs/user_guide/triangle.ipynb +++ b/docs/user_guide/triangle.ipynb @@ -3214,12 +3214,7 @@ "```{warning}\n", "Virtual columns have limited support. Estimators such as `Development` and\n", "`Chainladder` do not evaluate them, so their results for a virtual column are\n", - "all NaN, with no warning. The `link_ratio` and `age_to_age` properties apply\n", - "the column's expression to the link ratios of the other columns. The result matches\n", - "the column's own link ratios for a quotient such as `PaidLossRatio`, but not in\n", - "general, for example for a difference of two columns. Select a virtual column\n", - "first, for example `clrd.sum()[\"PaidLossRatio\"]`, to get an ordinary Triangle\n", - "that these properties and estimators handle correctly.\n", + "all NaN, with no warning.\n", "```" ] },