ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Charts and Charting in Excel (https://www.excelbanter.com/charts-charting-excel/)
-   -   XY Scatter Plot - Stringline for Trains (https://www.excelbanter.com/charts-charting-excel/41343-xy-scatter-plot-stringline-trains.html)

JahMuse

XY Scatter Plot - Stringline for Trains
 

I have a stringline chart I have made out of the XY scatter plot chart
for trains in our area. The file is a program that allows users to
input a train number (e.g. 520), start time (8:20 - using military
time) and a starting location and an ending location. This if for my
boss so he can experiment with various train schedule and see the
trains in a stringline diagram (time of day vs. mileposts for each
train). I currently have all the trains plotted against the mileposts
and, correctly, some trains start and end midway where as others
complete the entire run. My problem is I am getting some stringlines
that extend all the way back to the mileposts on the XY intersection so
the graph mostly looks good except for these long and sometimes dense
(with all the plots) lines heading across the chart. They are tied to a
0:00 point which I swear is not part of the data being plotted.

I would be happy to send the file to anyone curious enough to look into
this. My two help books have nothing on this so I am your hands gracious
reader.

Thanks-


--
JahMuse
------------------------------------------------------------------------
JahMuse's Profile: http://www.excelforum.com/member.php...o&userid=26470
View this thread: http://www.excelforum.com/showthread...hreadid=397389


Jon Peltier

It sounds like you have a non numeric, non blank cell, which Excel interprets as a
zero. If you are doing your data using formulas, you might have one that reads like
this:

=IF(<condition,<result,"")

The "" does not make it a blank cell, instead it's a text value, or zero. Normally
the workaround is to replace "" with NA(), but this will still produce a line
between the points on either side of the point with NA().

I think what you'll have to do, if you're using formulas, is allow for two series
per train route. One series goes from the start of the route until it reaches one
edge of the chart, the other goes from the other edge and continues to the end of
the route.

You could also try workarounds that hide the line which spans the NA() gap. Look on
Tushar Mehta's web site (http://tushar-mehta.com) and Andy Pope's site
(http://andypope.info).

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______

JahMuse wrote:
I have a stringline chart I have made out of the XY scatter plot chart
for trains in our area. The file is a program that allows users to
input a train number (e.g. 520), start time (8:20 - using military
time) and a starting location and an ending location. This if for my
boss so he can experiment with various train schedule and see the
trains in a stringline diagram (time of day vs. mileposts for each
train). I currently have all the trains plotted against the mileposts
and, correctly, some trains start and end midway where as others
complete the entire run. My problem is I am getting some stringlines
that extend all the way back to the mileposts on the XY intersection so
the graph mostly looks good except for these long and sometimes dense
(with all the plots) lines heading across the chart. They are tied to a
0:00 point which I swear is not part of the data being plotted.

I would be happy to send the file to anyone curious enough to look into
this. My two help books have nothing on this so I am your hands gracious
reader.

Thanks-




JahMuse


I changed those "" to a NA() and then utilized the Tool Pack plugin and
the stretched lines went away.

If this file is exported to a different computer, however, won't I need
to have them first of all have the tool packs plugged in and then this
NA() plotting solution addressed for each machine this works on?


--
JahMuse
------------------------------------------------------------------------
JahMuse's Profile: http://www.excelforum.com/member.php...o&userid=26470
View this thread: http://www.excelforum.com/showthread...hreadid=397389


Jon Peltier

Maybe not. What are you using the Toolpak for?

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services
Tutorials and Custom Solutions
http://PeltierTech.com/
_______

JahMuse wrote:
I changed those "" to a NA() and then utilized the Tool Pack plugin and
the stretched lines went away.

If this file is exported to a different computer, however, won't I need
to have them first of all have the tool packs plugged in and then this
NA() plotting solution addressed for each machine this works on?




JahMuse


You could also try workarounds that hide the line which spans the NA()
gap. Look on
Tushar Mehta's web site (http://tushar-mehta.com) -

This is exactly what I did - I only had to change my prior data values
for "blanks" "" to NA() and then that was the fix. The graph looks
excellent now. It just needs other program refinements unique to our
service but it does the job I thought/hoped it could.

Thank you for your advice.


--
JahMuse
------------------------------------------------------------------------
JahMuse's Profile: http://www.excelforum.com/member.php...o&userid=26470
View this thread: http://www.excelforum.com/showthread...hreadid=397389



All times are GMT +1. The time now is 05:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com