Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am working on making a scatter plot in Excel of some temperature data. I have

column A containing the date data as mm/dd/yy. column B containing the time data as hh:mm:ss AM/PM and the rest of the columns containing temperature data.

I am able to make a graph and get it to the axis size I want, however when I change the X-axis to a time variable, it somehow thinks the date is changing and not the time. I have about 4 hours of data, so I know this is incorrect. I am getting something like 1/0/00 12:00 AM when I really should be getting 4/3/13 1:50:59 PM. Does anyone know how to change the Excel settings to get the time I want?

share|improve this question

migrated from Apr 23 '13 at 22:30

This question came from our site for professional and enthusiast programmers.

I think it's not a settings issue. Add the two fields: "theDate" + "theTime".

Excel stores dates and times as floating point values (the integer part represents the date and the decimal part represents the time).

After that, simply format this new "DateTime" value like a time (hh:mm:ss or something like that)

share|improve this answer
I tried modifying the two fields and also tried removing the date field to no avail. – user1207381 Apr 22 '13 at 22:30
check the value of the cell (either in VBA debug window print the value of the cell or format it with a "general" or "numeric" format... times (without a date attached), are stored as 0.dddddd values; if they have an integer part, then somehow the time is being stored as a "date-time" value. Or use something like this: =int(yourDate) + (yourTime - int(yourTime)) – Barranka Apr 22 '13 at 22:37
This is the correct answer. It's just in the implementation. @user1207381 if you can post some screenshots of your data that would help. – David Zemens Apr 23 '13 at 2:29
1. Make sure that your dates and times are numerical, so adding them does not produce nonsensical values. – Jon Peltier Apr 26 '13 at 13:03
2. A line chart can only distinguish date-time values with the granularity of days (whole numbers). All points for a given day occur at the axis position of the starting time of the date (i.e., midnight). Use an XY Scatter chart. – Jon Peltier Apr 26 '13 at 13:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .