[REVIEW] fdo#33773 X-Axis Error Bars

Rafael Dominguez venccsralph at gmail.com
Fri Jun 1 15:37:37 PDT 2012


On Fri, Jun 1, 2012 at 4:33 PM, Kohei Yoshida <kohei.yoshida at gmail.com>wrote:

> On Fri, 2012-06-01 at 14:05 -0400, Kohei Yoshida wrote:
> > Hello Rafael,
> >
> > On Fri, 2012-06-01 at 11:13 -0430, Rafael Dominguez wrote:
> >
> > > i tried a lot of ideas and looked at how other code handle it but i
> > > cant seem to get it work, if you could check it out and fix it or tell
> > > me whats wrong, that would
> > > be highly appreciated.
> >
> > As we chatted on IRC, I'll try to look into this and hopefully come up
> > with an answer.  The code around is a bit tricky so give me some time to
> > get up to speed on this.
>
> So, what I did is to build the latest version of master, and played with
> X error bars in chart.  Here is what I see.
>
> When I set X error bars, specify the range for the positive and negative
> error var values, it gets set correctly.  This is good.
>
> When I save that file, and inspects what gets saved in the XML stream of
> that ods file, the ranges I set for X error bars are not saved.  Only
> those ranges for the Y error bars are saved.
>
> Another thing I noticed is that, the ranges for the Y error bars are
> saved in the style properties that are used by the <chart:series>
> element.  Those attribute names alone don't specify whether they are for
> the X or Y bars, and during import we import them for Y error bars,
> which is odd.
>
> I don't know that the ODF spec specifies, but for this to work for both
> X and Y error bars, we need to store these ranges in the style
> properties that are used for the <chart:error-indicator> element.
> Otherwise we won't be able to distinguish whether they are the X error
> bars or Y error bars.  I've checked the spec, but the spec is awfully
> terse about this and I have no clue whether the spec even cares about
> what element these attributes are used for.  So, for the moment we will
> assume that the spec doesn't impose any restriction regarding this.
>
> Given all this, we will need to first work on the export side, to store
> these attributes
>
> chart:error-upper-indicator
> chart:error-lower-indicator
> chart:error-category
> chart:error-upper-range
> chart:error-lower-range
>
> in the style properties that are used for the <chart:error-indicator>
> element, instead of those that are used for the <chart:series> element.
>
> Once that's taken care of, we can work on importing them properly.
>
> I hope this makes sense.  I don't know this was not an answer to your
> original question, but in my view, this needs to be worked on first.
>
> Best,
>
> Kohei
>
> --
> Kohei Yoshida, LibreOffice hacker, Calc
>
>
Sorry i forgot to tell you that the exporting code is not merged to master,
its in features/chart_errorbars i pushed the patch too to that branch.

About the spec, on ODF 1.2 it you have a dimension attribute to distinguish
between the bars, after that theres nothing on paper, what i did is add the
needed attributes to chart:error-indicator.
<http://cgit.freedesktop.org/libreoffice/core/log/?h=feature/chart_errorbars>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20120601/a91c41bd/attachment.htm>


More information about the LibreOffice mailing list