0

I'm trying to plot graphs for pressure and temperature recorded on different devices.

The number of data recorded for each device is different (Eg. pressure has 1 reading per second while temperature has 1 reading per 6 seconds). I want to plot the pressure on primary y-axis and temp.on secondary y-axis for a time period of 144 min (time on x-axis).

Now when i plot the graphs the usual way (Graph type: 2D line), the temp. plots stop somewhere in between the x-axis (I'm assuming the number of data points are insufficient to fill).

Is there a way for excel to decide that each series start and end at same time even if the number of data points are different?

Let me know if any additional inputs required.

6
  • Can you put in a screen shot and summarize the graph settings (graph type, axis settings, data range definitions)? Is the X axis treating the times as a continuous variable or categories?
    – fixer1234
    Commented Oct 15, 2014 at 8:31
  • Graph type-2D line, data range for pressure and temp is visible on the screenshot(sendspace.com/file/f66ok7). Both press and temp are measure from 0-144 minutes. But since number of data points for temp is less than that for pressure, the temp graph (blue in image) ends in the middle of the chart.
    – web
    Commented Oct 15, 2014 at 9:30
  • For the x-axis, I'm using time interval to be 1 second. I converted them into minutes for a clean plot on the chart)
    – web
    Commented Oct 15, 2014 at 10:04
  • 2
    Just a wild guess--the X axis values are being treated as categories instead of a continuous variable. Try using an XY graph instead of a line graph.
    – fixer1234
    Commented Oct 15, 2014 at 14:30
  • Thanks fixer, that worked! :) Another (bad?) solution I came across was creating a macro for selecting only one value for every 6 rows. This way the number of data points remain same for both temp. and pressure. Only problem is you have to lose some data to plot a simple graph. Just stating it here so others need not look around much.
    – web
    Commented Oct 16, 2014 at 5:36

1 Answer 1

1

As indicated in the comments, this was being plotted as a line graph. With a line graph, the X values can be treated as categories rather than a continuous variable. Categories don't have a scale, the axis values are just a series of display positions with labels. In this case, two independent series were plotted on the same axis. Excel doesn't match up category labels for the two data series. The temperature readings had fewer values so they just went into the first positions for as many categories as were needed. The solution is to use an XY graph, where X is always a continuous variable.

You must log in to answer this question.

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