From de4081e6d843a1e3b2a2a4c563ad6434c626377a Mon Sep 17 00:00:00 2001 From: Jason Stover Date: Sat, 11 Jul 2009 15:45:49 -0400 Subject: [PATCH] Return 0.0 for mean of a categorical variable. Fixes bug mentioned in bug report 26861. --- src/math/linreg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/math/linreg.c b/src/math/linreg.c index 609a78b6dc..2b4f7c9069 100644 --- a/src/math/linreg.c +++ b/src/math/linreg.c @@ -626,7 +626,7 @@ double pspp_linreg_get_indep_variable_mean (pspp_linreg_cache *c, const struct v coef = pspp_linreg_get_coeff (c, v, NULL); return pspp_coeff_get_mean (coef); } - return GSL_NAN; + return 0.0; } void pspp_linreg_set_indep_variable_mean (pspp_linreg_cache *c, const struct variable *v, -- 2.30.2