Created attachment 184088 [details] Trendline on a graph where the original data was then sorted by a different column Trend Lines appear to be created from raw table data so appear as a childlike scribble if table is re-sorted (graph is correct still though). It's very artistic looking, but totally useless. This has been broken since at least version 7.3 and I think well before. I've attached an image showing a 14 point moving average on a roughly 200 datapoint bar chart style graph to demonstrate the problem. If you resort into natural order again, then the trendline is correctly drawn hence my theory that the trendline is being drawn from the original table data rather than that used for rendering the graph.
> Created attachment 184088 [details] The screenshot its OK to see what do you wrote. But, please, share the spreadsheet to test on it. Thanks. But what I can see, the chart seems to be a Column and Line chart, not a Column chart with trend line.
To be absolutely clear, this is a line chart with a moving average trend line. No you cannot have the spreadsheet, it is proprietary data. I looked at what is needed to submit a bug report, and that was not part of the information requested. I'll see if I can create a new basic spreadsheet demonstrating the behaviour instead.
Sorry - "normal column chart"
Created attachment 184097 [details] This simple spreadsheet demonstrates the problem Here is a simple spreadsheet to prove the same 'feature'. Note that the x axis column must be a series of dates to cause the bizarre issue. I tried with an incrementing sequence first and that didn't do the trick.
I've now uploaded a demonstration spreadsheet.
I repro: I clicked the Random number autofilter and sorted ascending. Already seen in 5.2 and 4.2. Arch Linux 64-bit, X11 Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: 013fbfb592f71c1f0a60b6a7ec08aded375515ac CPU threads: 8; OS: Linux 6.2; UI render: default; VCL: kf5 (cairo+xcb) Locale: fi-FI (fi_FI.UTF-8); UI: en-US Calc: threaded Built on 9 March 2023