Re: [sc-dev] Table Highlighting
Kohei Yoshida wrote: Along the same line, I would also like to see the possibility of overlaying (or underlaying) a background image to enhance the visual effect of Calc's (rather boring) sheet. Note that such background image is not printable, so it's only for display. And it wouldn't scroll with the sheet; it stays at the fixed position, or may be aligned with the frame so that it moves when the app's frame gets resized. I think this would be a nice PR feature, don't ya think ? ;-) http://idea.opensuse.org/content/ideas/oo.o-calc-with-background-sheet-picture Not scrolling the image would mean that Window::Scroll can't be used. Other than that, it seems possible. Niklas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] Finance Functions
gcavalcanti wrote: Anybody knows where are the finance functions (ex. TIR,PV,RATE...) in the OpenOffice sources? I looked in the directory OOF680_m14\sc\source\core\tool\interpr*.cxx, but without success... Those that aren't add-in function are just there, but some have non-obvious names (ScZins for RATE, ScBW for PV, ScIKV for IRR). Niklas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] Finance Functions
On Thu, 2007-07-05 at 14:21 -0300, gcavalcanti wrote: > Hello, > > Anybody knows where are the finance functions (ex. TIR,PV,RATE...) in the > OpenOffice sources? > > I looked in the directory OOF680_m14\sc\source\core\tool\interpr*.cxx, but > without success... They are probably in the scaddins module. Take a look at scaddins/source/analysis/financial.cxx. Kohei - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] Table Highlighting
On Thu, 2007-07-05 at 19:04 +0200, Niklas Nebel wrote: > Leonard Mada wrote: > > I posted some time back a feature-request to implement a special > > spreadsheet-view in which rows get *highlighted* (see > > http://www.openoffice.org/issues/show_bug.cgi?id=78181). > > > > Virtually every table on the net is displayed this way. Also, most web > > applications have implemented it (see e.g. phpMyAdmin for one, but there > > are countless others). The code for the net applications is a mere > > 20-line java-script (I used it, too). > > > > Would it be possible to implement this in Calc? > > Actually exchanging a highlight color for the cell background would > require changes to the output (rendering) code. Instead, current fashion > calls for an overlay object, which could highlight the row by painting a > transparent color over it. Along the same line, I would also like to see the possibility of overlaying (or underlaying) a background image to enhance the visual effect of Calc's (rather boring) sheet. Note that such background image is not printable, so it's only for display. And it wouldn't scroll with the sheet; it stays at the fixed position, or may be aligned with the frame so that it moves when the app's frame gets resized. I think this would be a nice PR feature, don't ya think ? ;-) http://idea.opensuse.org/content/ideas/oo.o-calc-with-background-sheet-picture Kohei - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-dev] Finance Functions
Hello, Anybody knows where are the finance functions (ex. TIR,PV,RATE...) in the OpenOffice sources? I looked in the directory OOF680_m14\sc\source\core\tool\interpr*.cxx, but without success... Thanks, Guilherme - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] Table Highlighting
Leonard Mada wrote: I posted some time back a feature-request to implement a special spreadsheet-view in which rows get *highlighted* (see http://www.openoffice.org/issues/show_bug.cgi?id=78181). Virtually every table on the net is displayed this way. Also, most web applications have implemented it (see e.g. phpMyAdmin for one, but there are countless others). The code for the net applications is a mere 20-line java-script (I used it, too). Would it be possible to implement this in Calc? Actually exchanging a highlight color for the cell background would require changes to the output (rendering) code. Instead, current fashion calls for an overlay object, which could highlight the row by painting a transparent color over it. Niklas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-dev] Table Highlighting
Hello Niklas, helle Eike, I posted some time back a feature-request to implement a special spreadsheet-view in which rows get *highlighted* (see http://www.openoffice.org/issues/show_bug.cgi?id=78181). Virtually every table on the net is displayed this way. Also, most web applications have implemented it (see e.g. phpMyAdmin for one, but there are countless others). The code for the net applications is a mere 20-line java-script (I used it, too). Would it be possible to implement this in Calc? And who is most responsible for these UI-related issues? Thanks, Leonard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Regina Henschel wrote: ... I'll work on CORREL, PEARSON, RSQ, STEYX, SLOPE, INTERCEPT and FORECAST (all in interpr3.cxx), which I think all suffer from the same "square"-problem. The function GetStVarParams in interpr1.cxx is OK in this respect and therefore also the DEVSQ, STDEV and VAR. kind regards Regina Great! Let me know if there are any questions regarding the algorithms or the statistics. I was pretty busy lately (and still am :-( ), but I would try to free some time to solve the problem if there is one. Many thanks, Leonard - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hi Regina, On Thursday, 2007-07-05 13:59:32 +0200, Regina Henschel wrote: > I'll work on CORREL, PEARSON, RSQ, STEYX, SLOPE, INTERCEPT and FORECAST > (all in interpr3.cxx), Much appreciated! Thanks Eike -- OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer. OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't send personal mail to this [EMAIL PROTECTED] account, which I use for mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hi Regina, On Thursday, 2007-07-05 13:06:15 +0200, Regina Henschel wrote: > >recent SRC680 milestone (latest available now is m219) > > m219 is not on the mirrors and I have used CVS not yet. The m218 > tarballs are available on the mirros. I would then have to do another 18 > hours build. I own only a "normal" PC with WinXP. Nevertheless, that > would be practicable for me. Would it be OK with the m218 version? Sure, m218 is fine. Thank you. Eike -- OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer. OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't send personal mail to this [EMAIL PROTECTED] account, which I use for mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hello Niklas, Niklas Nebel schrieb: Regina Henschel wrote: I had a look at the source in interpr3.cxx and have made the proposed changes for the COVAR function. Although I'm a very beginner I think, that I'm able to change some of the other such functions too. The changes need to calculate the mean in a first loop and than calculating the other results in a second loop. My question is, whether you want, that the functions are changed in that way. If yes, I would be glad, to do that job. For COVAR it looks like this (based on OOF680_m18): Yes, this looks very good and should be changed that way. Which other functions do you plan to modify? I'll work on CORREL, PEARSON, RSQ, STEYX, SLOPE, INTERCEPT and FORECAST (all in interpr3.cxx), which I think all suffer from the same "square"-problem. The function GetStVarParams in interpr1.cxx is OK in this respect and therefore also the DEVSQ, STDEV and VAR. kind regards Regina - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hi, Accessing CVS is not really a problem nowadays. Download one of the freely available IDEs (like Netbeans, Eclipse) and your are only away a few clicks from the source and patch tools. Eclipse even provides an specialized download for C++-Developers (CDT [1] & [2]) I'm not sure aboute netbeans but I think it also provides such a beast :-) Tom [1] http://www.eclipse.org/downloads/ [2] http://cdtdoug.blogspot.com/2007/06/introducing-cdt-for-windows.html Regina Henschel schrieb: Hello Eike, Eike Rathke schrieb: Hi Regina, On Thursday, 2007-07-05 10:34:37 +0200, Regina Henschel wrote: For COVAR it looks like this (based on OOF680_m18): Very nice, indeed. Could you do us a favor though and base your changes on a recent SRC680 milestone (latest available now is m219) instead of OOF680, chances then are much higher that patches seamlessly apply. m219 is not on the mirrors and I have used CVS not yet. The m218 tarballs are available on the mirros. I would then have to do another 18 hours build. I own only a "normal" PC with WinXP. Nevertheless, that would be practicable for me. Would it be OK with the m218 version? kind regards Regina - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hello Eike, Eike Rathke schrieb: Hi Regina, On Thursday, 2007-07-05 10:34:37 +0200, Regina Henschel wrote: For COVAR it looks like this (based on OOF680_m18): Very nice, indeed. Could you do us a favor though and base your changes on a recent SRC680 milestone (latest available now is m219) instead of OOF680, chances then are much higher that patches seamlessly apply. m219 is not on the mirrors and I have used CVS not yet. The m218 tarballs are available on the mirros. I would then have to do another 18 hours build. I own only a "normal" PC with WinXP. Nevertheless, that would be practicable for me. Would it be OK with the m218 version? kind regards Regina - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Hi Regina, On Thursday, 2007-07-05 10:34:37 +0200, Regina Henschel wrote: > For COVAR it looks like this (based on OOF680_m18): Very nice, indeed. Could you do us a favor though and base your changes on a recent SRC680 milestone (latest available now is m219) instead of OOF680, chances then are much higher that patches seamlessly apply. Thanks Eike -- OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer. OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't send personal mail to this [EMAIL PROTECTED] account, which I use for mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] Thanks. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [sc-dev] stable algorithm for statistic functions issue 78250
Regina Henschel wrote: I had a look at the source in interpr3.cxx and have made the proposed changes for the COVAR function. Although I'm a very beginner I think, that I'm able to change some of the other such functions too. The changes need to calculate the mean in a first loop and than calculating the other results in a second loop. My question is, whether you want, that the functions are changed in that way. If yes, I would be glad, to do that job. For COVAR it looks like this (based on OOF680_m18): Yes, this looks very good and should be changed that way. Which other functions do you plan to modify? Niklas - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-dev] stable algorithm for statistic functions issue 78250
Hello, I had a look at the source in interpr3.cxx and have made the proposed changes for the COVAR function. Although I'm a very beginner I think, that I'm able to change some of the other such functions too. The changes need to calculate the mean in a first loop and than calculating the other results in a second loop. My question is, whether you want, that the functions are changed in that way. If yes, I would be glad, to do that job. For COVAR it looks like this (based on OOF680_m18): --- interpr3original.cxx2006-07-21 13:34:30.0 +0200 +++ interpr3Version1Covar.cxx 2007-07-04 23:00:28.65625 +0200 @@ -3656,13 +3656,18 @@ SetIllegalParameter(); return; } + //#issue 78250 + //(sum((X-MeanX)(Y-MeanY)))/N equals (SumXY)/N-MeanX*MeanY mathematically, + // but the latter produces wrong results if the absolute values are high, + // for example above 10^7 double fCount = 0.0; double fSumX= 0.0; double fSumY= 0.0; - double fSumXY = 0.0; + double fSumDeltaXDeltaY = 0.0; // sum of (ValX-MeanX)*(ValY-MeanY) double fValX, fValY; + double fMeanX, fMeanY; for (SCSIZE i = 0; i < nC1; i++) - for (SCSIZE j = 0; j < nR1; j++) + for (SCSIZE j = 0; j < nR1; j++) { if (!pMat1->IsString(i,j) && !pMat2->IsString(i,j)) { @@ -3670,14 +3675,27 @@ fValY = pMat2->GetDouble(i,j); fSumX+= fValX; fSumY+= fValY; - fSumXY += fValX*fValY; fCount++; } } if (fCount < 1.0) SetNoValue(); else - PushDouble( (fSumXY-fSumX*fSumY/fCount)/fCount); + { +fMeanX = fSumX/fCount; +fMeanY = fSumY/fCount; +for (SCSIZE i = 0; i < nC1; i++) + for (SCSIZE j = 0; j < nR1; j++) + { + if (!pMat1->IsString(i,j) && !pMat2->IsString(i,j)) + { + fValX = pMat1->GetDouble(i,j); + fValY = pMat2->GetDouble(i,j); + fSumDeltaXDeltaY +=(fValX-fMeanX)*(fValY-fMeanY); + } + } + PushDouble( fSumDeltaXDeltaY/fCount); + } } kind regards Regina - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]