summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.com>2016-01-24 15:08:05 +0100
committerEike Rathke <erack@redhat.com>2016-01-25 16:10:39 +0000
commitf3dbf9cbba6e1d5917de9793a95eced4182777b8 (patch)
treee1f4825556809af4b1d35812a40ef5be37b0e49e
parent6e193148df69eff428fec23560e9d3ad4f503597 (diff)
tdf#74667 interchange slope and intercept for power regression
Change-Id: I9da7edeabcc9f963ac19d26114fa101d4b5ce98f (cherry picked from commit 4d67b0baaa4f0fb009b9ee6fbcf4618abf009f53) Reviewed-on: https://gerrit.libreoffice.org/21743 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
-rw-r--r--sc/source/ui/StatisticsDialogs/RegressionDialog.cxx6
1 files changed, 3 insertions, 3 deletions
diff --git a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
index ad092eeb03d0..84939a8c655e 100644
--- a/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
+++ b/sc/source/ui/StatisticsDialogs/RegressionDialog.cxx
@@ -53,21 +53,21 @@ namespace
{
"=SLOPE(%VARIABLE2_RANGE% ; %VARIABLE1_RANGE%)",
"=SLOPE(%VARIABLE2_RANGE% ; LN(%VARIABLE1_RANGE%))",
- "=EXP(INTERCEPT(LN(%VARIABLE2_RANGE%) ; LN(%VARIABLE1_RANGE%)))"
+ "=SLOPE(LN(%VARIABLE2_RANGE%) ; LN(%VARIABLE1_RANGE%))"
};
OUString constTemplatesINTERCEPT[] =
{
"=INTERCEPT(%VARIABLE2_RANGE% ; %VARIABLE1_RANGE%)",
"=INTERCEPT(%VARIABLE2_RANGE% ; LN(%VARIABLE1_RANGE%))",
- "=SLOPE(LN(%VARIABLE2_RANGE%) ; LN(%VARIABLE1_RANGE%))"
+ "=EXP(INTERCEPT(LN(%VARIABLE2_RANGE%) ; LN(%VARIABLE1_RANGE%)))"
};
OUString constRegressionFormula[] =
{
"=%A% * %ADDRESS% + %B%",
"=%A% * LN(%ADDRESS%) + %B%",
- "=%A% * %ADDRESS% ^ %B%"
+ "=%B% * %ADDRESS% ^ %A%"
};
} // end anonymous namespace