[Solved] Month and day from Datetime as X-axis labels

Discuss the spreadsheet application
Locked
sevensixtwo
Posts: 3
Joined: Sat Feb 10, 2024 1:45 pm

[Solved] Month and day from Datetime as X-axis labels

Post by sevensixtwo »

I am plotting a number as the y-axis and a datetime as the x-axis. When the x-axis tickmarks get made, it is converting the datetime to a number, e.g.: "45330." How do I get tickmarks that look like "Feb 10" or similar on the x-axis? A tickmark like an .ods date "02/10/24" would also be ok, but less preferable.
TEST.ods
(17.45 KiB) Downloaded 50 times
Last edited by sevensixtwo on Sat Feb 10, 2024 6:46 pm, edited 2 times in total.
OpenOffice 3.1 on Windows 11
User avatar
Hagar Delest
Moderator
Posts: 32668
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Month and day from Datetime as x-axis tickmarks

Post by Hagar Delest »

Hi and welcome to the forum!

Either you format the source value and make the X axis keep the source format in the Numbers tab of the X axis properties. Or you tune the X axis format, again in the Numbers tab of its properties.

See:
TEST Hagar.ods
(24.01 KiB) Downloaded 48 times
Please add [Solved] at the beginning of the title in your first post (top of the topic) with the πŸ–‰ button if your issue has been fixed.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
sevensixtwo
Posts: 3
Joined: Sat Feb 10, 2024 1:45 pm

Re: Month and day from Datetime as x-axis tickmarks

Post by sevensixtwo »

Great, thanks. I did not realize that I could click on the x-axis to get its properties!
OpenOffice 3.1 on Windows 11
sevensixtwo
Posts: 3
Joined: Sat Feb 10, 2024 1:45 pm

Re: Month and day from Datetime as x-axis tickmarks

Post by sevensixtwo »

I have a few more questions, please. How do I add x- and y-axis labels to say "weight" and "date." Also, I added a best fit line, and I want to have the slope of the line displayed in the chart, computed in units of [number]/[days]? Thanks!
Attachments
TEST2.ods
(18.38 KiB) Downloaded 53 times
OpenOffice 3.1 on Windows 11
User avatar
MrProgrammer
Moderator
Posts: 4909
Joined: Fri Jun 04, 2010 7:57 pm
Location: Wisconsin, USA

Re: Month and day from Datetime as x-axis tickmarks

Post by MrProgrammer »

Hi, and welcome to the forum. Thank you for the attachment.
sevensixtwo wrote: ↑Sat Feb 10, 2024 5:00 pm How do I add x- and y-axis labels to say "weight" and "date."
Insert β†’ Titles β†’ Axes β†’ X axis β†’ Date β†’ Y axis β†’ Weight β†’ OK

sevensixtwo wrote: ↑Sat Feb 10, 2024 5:00 pm I want to have the slope of the line displayed in the chart
Click the trend line β†’ Format β†’ Format selection β†’ Type β†’ Show equation β†’ OK
Click the equation β†’ Format β†’ Format selection β†’ Numbers β†’ Decimal places β†’ Your choice β†’ OK

sevensixtwo wrote: ↑Sat Feb 10, 2024 4:45 pm I did not realize that I could click on the x-axis to get its properties!
Calc Guide Chapter 3: Creating Charts and Graphs

If this solved your problem please go to your first post use the Edit ☐ button and add [Solved] to the start of the Subject field. Select the green checkmark icon at the same time.

[Tutorial] Ten concepts that every Calc user should know
Mr. Programmer
AOO 4.1.7 Build 9800, MacOS 13.6.3, iMac Intel.Β Β  The locale for any menus or Calc formulas in my posts is English (USA).
Locked