drawing lines

  • Thread starter Ron Croonenberg
  • Start date
R

Ron Croonenberg

Hello,

I am new to excel, never really used it.

How do I draw a line if I now the equation/formula.

let's say I want to plot/draw the line 2x + y = 20 (for all x>=0 and all
y>=0).

Is there an easy way to put that in a graph ?

thanks,

Ron
 
M

Mike Middleton

Ron Croonenberg -
I am new to excel, never really used it. How do I draw a line if I now
the equation/formula. let's say I want to plot/draw the line 2x + y = 20
(for all x>=0 and all y>=0). Is there an easy way to put that in a graph ? <

Use an XY (Scatter) chart for this task. Excel plots points from worksheet
data (pairs of numbers), and the chart can be formatted to show lines
connecting the points.

For example, enter X values in a column on the left, e.g., in A1 thru A20.
From algebra, y = 20 - 2x. For Y values in a column on the right, in cell B1
enter the formula =20-2*A1, edit copy, and edit paste to B2 thru B20 (or
click and drag).

Select cells A1 thru B20, and use the ChartWizard to create an XY (Scatter)
chart. (The ChartWizard assumes X on left and Y on right if there are three
or more rows.)

If you want to modify the point markers or lines, click on one of the points
to select the series, and choose Format ... If you want to change an axis,
right-click it ...

For your example (linear function) your need only two endpoints (instead of
20) to define the line (in which case you'll need to specify that the data
series are in columns using step 2 of the ChartWizard).

- Mike Middleton, www.usfca.edu/~middleton
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top