Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default Charts with Time as X-Axis

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed
  #2   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default Charts with Time as X-Axis

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default Charts with Time as X-Axis

Try scatter plot instead of line plot.

"Ed" wrote:

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 220
Default Charts with Time as X-Axis

You have to use a Scatter chart, not a Line chart. You should then get what
you want. And you can change the format of the cells to just show the time
if you want. You don't have to show the date also.

HTH,

Eric


"Ed" wrote:

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed

  #5   Report Post  
Posted to microsoft.public.excel.programming
Ed Ed is offline
external usenet poster
 
Posts: 279
Default Charts with Time as X-Axis

That sort of works. In some cases, it looks like there are more than one
data point for the same time. My guess is because there are so many time
data points (every 30 seconds for several hours) that when the chart
compresses it, it looks like two points at the same time, esp. if I use a
Scatter with Smooth Lines.

It would be most handy if I could play a Line chart or Stock chart with
seconds or minutes on the X-axis, but apparently this is not available.
--
Ed


"EricG" wrote:

You have to use a Scatter chart, not a Line chart. You should then get what
you want. And you can change the format of the cells to just show the time
if you want. You don't have to show the date also.

HTH,

Eric


"Ed" wrote:

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default Charts with Time as X-Axis

Try reformat the axis. Click on the x-axis to select the axis. then double
click on the axis. I box will appear that allows reformating of the axis.
If the box doesn't appear try a couple of times. It is a little tricky in
getting the format box to appear.

"Ed" wrote:

That sort of works. In some cases, it looks like there are more than one
data point for the same time. My guess is because there are so many time
data points (every 30 seconds for several hours) that when the chart
compresses it, it looks like two points at the same time, esp. if I use a
Scatter with Smooth Lines.

It would be most handy if I could play a Line chart or Stock chart with
seconds or minutes on the X-axis, but apparently this is not available.
--
Ed


"EricG" wrote:

You have to use a Scatter chart, not a Line chart. You should then get what
you want. And you can change the format of the cells to just show the time
if you want. You don't have to show the date also.

HTH,

Eric


"Ed" wrote:

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed

  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 220
Default Charts with Time as X-Axis

Since it's a scatter chart, you can actually have two y-values for the same
x-value. And yes, if your data is very dense compared to the axis scale, it
will look like the points are on top of each other.

If you want to run a line through the data that might improve the
appearance, try adding a trendline, using a moving average. Play with the
number of points in the average until you get something you like.

You could always try to simulate a Stock chart with the Scatter chart, but
it would probably involve some behind-the-scenes VBA help and might get
ugly...

Eric

"Ed" wrote:

That sort of works. In some cases, it looks like there are more than one
data point for the same time. My guess is because there are so many time
data points (every 30 seconds for several hours) that when the chart
compresses it, it looks like two points at the same time, esp. if I use a
Scatter with Smooth Lines.

It would be most handy if I could play a Line chart or Stock chart with
seconds or minutes on the X-axis, but apparently this is not available.
--
Ed


"EricG" wrote:

You have to use a Scatter chart, not a Line chart. You should then get what
you want. And you can change the format of the cells to just show the time
if you want. You don't have to show the date also.

HTH,

Eric


"Ed" wrote:

Incidentally, I'm using Excel 2007.

That's exactly what I've done. My X-axis series contains e.g. 6/3/2009
7:30:00 AM, 6/3/2009 7:30:30 AM, 6/3/2009 7:31:00 AM, etc. The first column
on the spreadsheet contains this time data, and the second column contains
the price. I highlight the two columns and click Insert-Line-2D Line, and
a chart comes up with only one point on the X-Axis labeled '6/3/2009 0:00'
(and a straight vertical line on the graph covering the price range). When I
highlight the X-axis on the chart, right-click, and click Format Axis, 'Major
unit' and 'Minor unit' are defaulted to 'Auto' (where it gives only one point
on the X-axis). If I click on Fixed, it only allows for Days, Months, or
Years, but not e.g. seconds.
--
Ed


"Joel" wrote:

You x-axis has to contain a day and time to get smaller divisions. Make one
column in your source data contain both the data and time in the same cell
like
6/17/09 09:00. the graph will match the same time division and the source
data.

"Ed" wrote:

I would like to plot some stock prices for a stock during one day. In other
words, the X-axis will contain a series all with the same date but with
different times during the day, and the Y-axis will contain the prices.
However, it appears the smallest increment for either Line charts or Stock
charts is only one day (i.e. it plots all of my X-axis data as if it were one
point since it is all in the same day). Is there a way around this?
--
Ed

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Charts with Time as X-Axis Joel Excel Programming 0 June 17th 09 09:12 PM
Time Scales on Horizontal Axis - Excel Charts SusieQ Charts and Charting in Excel 1 December 13th 08 11:27 AM
Excel 2003- Charts- date and time format on x-axis of XY chart Elizabeth Charts and Charting in Excel 3 October 4th 07 12:08 AM
Excel Charts - Time line for random points on X axis Anjalika Silva Excel Worksheet Functions 2 January 10th 06 09:22 PM
Hiding Values Below Z Axis Minimum Value on Axis Charts TryingToExcel Charts and Charting in Excel 1 February 18th 05 03:55 AM


All times are GMT +1. The time now is 02:56 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"