Created attachment 86905 [details] COVAR COVARIATE.P COVARIATE.S not correctly handled in Calc The Excel functions COVARIATE.S and COVARIATE.P are not handled correctly in LibreOffice Calc. Please add the correct handling of these functions. According to the source document, this should be easy and a low hanging fruit :-) Please import attached spreadsheet (created in Excel 2010) in LibreOffice Calc. To test the correctness of the functions, please change a single value in either array 1 or array 2. In cell B1 you see the function COVAR which is correclty handled by Calc. However, Microsoft deprecated this function (it is still there for compatability reasons) and created the successor COVARIATE.P. However, the function COVARIATE.P (cell B2) is not correctly handled by Calc, although the source document states that a "Direct mapping possible". Currently, Calc reports and error on COVARIATE.P. Microsoft created a new function COVARIATE.S (cell B3) which is currently not supported by Calc, but "implementation would be easy, just copy code from COVAR and use different denominator" according to the source document. Currently, Calc reports and error on COVARIATE.S. "Source document" on handling the new Excle functions in Calc: http://wiki.openoffice.org/wiki/Calc/Drafts/Treatment_of_new_Excel_2010_functions#COVARIANCE.P
I feel free to add Eike to this bug/enhancement, because he dealt with a similar enhancement in bug 60032. Please remove yourself, if you don't like to be CCed here. Thanks!
@Winfried: Maybe something for you?
(In reply to comment #2) > @Winfried: > Maybe something for you? Bait taken ;)
Winfried Donkers committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=ccbebd991b6bbce30d10b88f464140338f706c5b fdo#70000 add support for COVARIANCE.P and COVARIANCE.S functions The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Eike Rathke committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=ac0dc48b63d93155304dfc44bd8f83adc4ae0825 check fCount beforehand and bail out early, fdo#70000 related The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Winfried Donkers committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=cea5b8eb497f7b162ea1743401c9045d286e5d8e fdo#70000 fix omission in support of Excel 2010 The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.