+ Reply to Thread
Results 1 to 5 of 5

Why does my chart look weird if I use dates as the 'x' axis values?

  1. #1
    Registered User
    Join Date
    01-04-2010
    Location
    Durham, NC (US)
    MS-Off Ver
    Excel 2007
    Posts
    4

    Why does my chart look weird if I use dates as the 'x' axis values?

    I have hourly values that I'd like to put into chart form (specifically, into a stacked area chart).

    The top chart in the attached spreadsheet uses the simple numerical series values in column A for the X axis, and the bottom chart uses the date/time values in column B.

    For the chart with the date series, Excel seems to want to clump all values from 10/21 into one column, and all values from 10/22 into another...

    How can I get the smooth curve with the dates in the X axis? Even better, can I get X axis labels that show only the dates (ex "Oct 21"), with sub-tick marks for the in-between values?
    Attached Files Attached Files

  2. #2
    Forum Expert mrice's Avatar
    Join Date
    06-22-2004
    Location
    Surrey, England
    MS-Off Ver
    Excel 2013
    Posts
    4,967

    Re: Why does my chart look weird if I use dates as the 'x' axis values?

    Your data range needs to be ='Sheet1'!$C$2:$F$31 and not ='Sheet1'!$B$1:$F$31

  3. #3
    Registered User
    Join Date
    01-04-2010
    Location
    Durham, NC (US)
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Why does my chart look weird if I use dates as the 'x' axis values?

    Quote Originally Posted by mrice View Post
    Your data range needs to be ='Sheet1'!$C$2:$F$31 and not ='Sheet1'!$B$1:$F$31
    Thanks, tried it, that doesn't actually help (well, it does fix the curve smoothing, but it also drops the dates from the axis labels--same effect as the first chart in the example). Excel seems to include the horizontal axis labels in what it calls the data range.

  4. #4
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,485

    Re: Why does my chart look weird if I use dates as the 'x' axis values?

    Date axis only go as fine as Days, not hours.

    If you correct date/time entry in cell B5 then you have equally spaced entries which means you can revert to Text axis.
    You can even use multi level category labels to get date and time
    Attached Files Attached Files
    Cheers
    Andy
    www.andypope.info

  5. #5
    Registered User
    Join Date
    01-04-2010
    Location
    Durham, NC (US)
    MS-Off Ver
    Excel 2007
    Posts
    4

    Re: Why does my chart look weird if I use dates as the 'x' axis values?

    Quote Originally Posted by Andy Pope View Post
    Date axis only go as fine as Days, not hours.

    If you correct date/time entry in cell B5 then you have equally spaced entries which means you can revert to Text axis.
    You can even use multi level category labels to get date and time
    Thanks. Not sure how I missed that, but even without the mistake, the test axis is something new for me, so learning about it is very helpful.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1