Bug 43983 - Explanation how chart Automatic axis scaling works required (see comment 5)
Summary: Explanation how chart Automatic axis scaling works required (see comment 5)
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Documentation (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: x86-64 (AMD64) All
: medium minor
Assignee: Not Assigned
Depends on:
Blocks: Help-Changes-Features
  Show dependency treegraph
Reported: 2011-12-20 08:11 UTC by Frieder
Modified: 2020-06-16 18:07 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:

Sample Document (33.40 KB, application/vnd.oasis.opendocument.spreadsheet)
2011-12-20 11:01 UTC, Rainer Bielefeld Retired
Sample (20.91 KB, application/vnd.oasis.opendocument.spreadsheet)
2011-12-20 12:06 UTC, Frieder
XY_Diagramm_Sample_2 (32.07 KB, application/vnd.oasis.opendocument.spreadsheet)
2011-12-20 22:32 UTC, Rainer Bielefeld Retired
XY_Diagramm_Sample not respecting minimum in LibO 4.4.1 (25.87 KB, application/pdf)
2015-03-08 17:11 UTC, Buovjaga

Note You need to log in before you can comment on or make changes to this bug.
Description Frieder 2011-12-20 08:11:29 UTC
If the Y-Axis in a X-Y diagram is set to "start automatically at minimum"
always starts at 0, no matter how big the minimum is.

Steps to reproduce:
-open new Calc document
-in the first column enter nummbers between 500 and 700
-in the second column enter any numbers you like
-create a X-Y chart with this da
-set the Y-Axis in the X-Y diagram to "start automatically at minimum"

It will start at 0 and not as expected at 480 or 460.
If you invert the axis, the X-axis starts at 450, 
which is not optimum but acceptable. 

This Bug appears in Version 3.3.4 ,3.4.4 and 3.5.0 on Linux and on Windows.
Comment 1 Rainer Bielefeld Retired 2011-12-20 10:59:39 UTC

NOT reproducible with Parallel Dev-Installation of "LibreOffice 3.5.0 Beta1 - WIN7 Home Premium (64bit) German UI [Build-ID: 7362ca8-b5a8e65-af86909-d471f98-61464c4] Windows_Release_Configuration  11-Dec-2011 06:51" and attached sample.ods.

I do not understand the sample and the report. Why should the first (500 ... 700) column contain y-axis values?

Please attach a sample document!
Comment 2 Rainer Bielefeld Retired 2011-12-20 11:01:34 UTC
Created attachment 54607 [details]
Sample Document

See comment 1
Comment 3 Frieder 2011-12-20 12:06:49 UTC
Created attachment 54610 [details]
Comment 4 Frieder 2011-12-20 12:21:24 UTC
I'm sorry  I interchanged the first and the second  column 
in my first description.
But in the sample it is correct.
Comment 5 Rainer Bielefeld Retired 2011-12-20 22:30:56 UTC
I compared the samples, had  an Idea an found th (or at least a) rule.

I my attachment Sample 3 on Table 2 You find a modified version of Frieder's Sample for your won experiments

The modifications are: Y-Values except start value will are calculated

The rule seems to be:
Only if result of "Y Value range" to "Y Minimum  Value" is equal or smaller to 0,2 the automatic Y start value adaption will become active.

Details can be discussed, but in general that is a useful feature, Please see example "XY_Diagramm_Sample_2.ods - Table 3". The chart shows a sinus oscillating around the Start value in C2.

For a start Value 10 it's a benefit to see the distance of the line from Y=0, most users can live with the white area below the curve (and to avoid it, you can scale Y-axis manually)

For a start Value 1.000.000 it's a benefit to avoid the distance of the chart curve from Y=0, with a normal scale showing all that 1.000.000 you can not see the sinus.

All the same with OOo 3.1.1

My Conclusion
Not a bug in function, but Help and Manual should explain how and when Automatic Ymin will be <> 0

I do not know whether I found all details of the rule, can you please check and forward information to David so that he can integrate it into help and manual?

Please feel free to reassign (or reset Assignee to default) if it’s not your area or if provided information is not sufficient. Please set Status to ASSIGNED if you accept this Bug.
Comment 6 Rainer Bielefeld Retired 2011-12-20 22:32:04 UTC
Created attachment 54624 [details]

See comment 5!
Comment 7 Frieder 2011-12-21 02:16:35 UTC
quote Rainer Bielefeld :
"For a start Value 10 it's a benefit to see the distance of the line from Y=0,
most users can live with the white area below the curve (and to avoid it, you
can scale Y-axis manually)"

Ok for some cases it seems to by a benefit 
to see the distance of the line from Y=0 .
But in that cases you can scale the Y-axis manually to start at 0.
The problem I have with the actual solution is,
that if I change the Y-Value of a diagram,
and I don't wont the Y-Axis start at 0
I have to rescale the axis every time I change the data.

At the time I help myself with a macro,
but that cant by the solution for a normal user.
For the macro code download the following Calc-document.(in German language)

So it would by great to have the choice between the actual solution,
and the real minimum of the Y-axis.
Comment 8 Rainer Bielefeld Retired 2011-12-21 02:32:32 UTC
(In reply to comment #7)

> I have to rescale the axis every time I change the data.

I agree, that might be annoying. 

I doubt that you can find an optimum for all needs, but an additional selection "opttimum fit axis to min-value - max-value" might have a good cost-benefit relation? May be you want to submit a separate enhancement request? Or we find one who can create an Extension?
Comment 9 Frieder 2011-12-21 04:02:25 UTC
>Or we find one who can create an Extension?

I can try to create an Extension for that,
but I think,  to have a extension only for that is a little bit overkill.
I can ad some more functionality.
For example to format several options of a  chart like intervals,
Axis position, Axis orientation .... by a formula in Calc.

But it will teak some time an till that will bee finished.
I knew all of the UNO API to do that by Basic-macro,
but I never built an extension before.
I found the Extension-Builder and the Extension-Compiler.
With these to tools  it should bee easy to make a Extension out of my macros,
but  it's still a lot of work to make help-texts, ad a licence ....
Comment 10 QA Administrators 2015-02-19 15:49:29 UTC Comment hidden (obsolete)
Comment 11 Buovjaga 2015-03-08 17:11:53 UTC Comment hidden (obsolete)
Comment 12 tommy27 2016-04-16 07:23:56 UTC Comment hidden (obsolete)
Comment 13 QA Administrators 2017-05-22 13:24:28 UTC Comment hidden (obsolete)
Comment 15 matthewnote 2020-06-16 18:07:53 UTC
"For a start Value 10 it's a benefit to see the distance of the line from Y=0,
most users can live with the white area below the curve (and to avoid it, you
can scale Y-axis manually)"

Here I'm providing an engineering analysis of medical evidence of disease proliferation (Y axis) due to logarithmic values of cause (X axis) and the autoscale is a huge problem.   I think the Bug is raised because nobody helped the Libreoffice team at the start with X,Y scatter reality.  To show the problem, creating two columns with row values the same, starting 75 to 150.  Plot the columns as X,Y scatter.  The X values are trimmed to autoscale, the Y axis still includes zero.   The difficulty is else than "most users" or "can live with it".   The line of points is expected to pass through the autoscale origin (both axes treated equally the same, of equal interest).  In engineering or mathematics, the work is without interest nor knowing if X causes Y or perhaps Y causes X.   That mental habit exists (due to histogram presentations) and often persists due to using X axis for "time" values.  However, in reality of work - the scale depends on the area of interest.  Autoscale zoom is very important.   In analysis or drawing office work you spend years learning how to do it by hand.  It's tough to find the computer won't.

Well, in the spreadsheet I'm providing, LibreOffice is excellent and solid, very stable.  However, twelve sheets with three graphics each, plotting 20000 points each, using 600 trend lines is pushing a Kaby Lake processor to it's limits.  Rescaling all charts at any choice of data change (global factors are necessary to analyse) has become impossible.   The charts are great, the workload to adjust is untenable (about two hours labour to adjust all graphics Y axes - every time one digit is changed). I'm a bit stuck.

To provide the user with the possibility to stretch out the autoscale "zoom", I provide each graphic with a cursor (one x value/coordinate, one y value/coordinate) set by the user.  Furthermore, all points with invalid x or y values are shoved under that cursor (using ERRORTYPE) so that trend lines do else than chaos.   It works, yet two thirds of every graphic is empty and the information (the variations) are squashed so hard on the Y axis as to be unreadable.   I use and ask medical staff to use a 4K monitor, yet still it's tough.   Workaround:  As well as the User Cursor cells, the spreadsheet here now offers a Y axis offset value.   When the user puts (for example) -100, the Y axis autoscale detects '0' is now crossed by some of the data and bingo, it snaps into useful presentation mode.   The user can still stretch out the window using the cursor. That is else than to please:  the variations often do have a tendency and stretching out to where that is makes sense of everything.  It's rarely (if ever) toward y=0.  that's a histogram thought.

(To make sure the user remembers he's altered the raw data, there's a very large white-on-black cell group that announces a warning about the offset and what it actually is.  It's the best I can do without macros).

It's understandable that placing a bug note about this might disturb, because the software works and the philosophy usually seems open to debate, yet in hard factual terms, favouring x or y axis (and not the other) as the only reference to be autoscaled is quite . . . . . .well, wrong.  (I know that's an awful word).