Forum Discussion
Charly3
Jun 02, 2026Copper Contributor
Error on regression analysis
Hello everyone, I want to perform a regression analysis on my survey data, but I keep getting this error message: “Regression - The RGP() function returns an error value. Check the input ranges.” I’...
NikolinoDE
Jun 09, 2026Platinum Contributor
When a single row breaks Excel's regression (RGP() or Analysis Toolpak), the cause is almost always one of three things:
- A non‑numeric value in that row – even a space, an empty string (""), or a number stored as text (green triangle).
- An error value – like #N/A or #VALUE!.
- A hidden range mismatch – removing the row accidentally aligns your X and Y ranges, which suggests the original ranges had different row counts.
To fix it quickly:
On the problematic row, use =ISTEXT(cell) and =ISERROR(cell) across your columns to find the offending cell. Then clean it with Text to Columns (Data tab) or a formula like =TRIM(cell)+0.
The "small numbers bug" and "Labels checkbox" are unlikely to be the issue here – they don't cause a single specific row to fail.
Hope this helps🙂