Using Nonadjacent ranges in Slope function

J

jsj

I am trying to use the slope (and intercept) worksheet functions. These work fine if the known_x (and known_y) values are from a contiguous range. However, I also need to produce slopes and intercepts from X (and Y) values that are nonadjacent.

Is there a way to do this. Simply putting brackets () around the entries doesn't seem to work. Here are some examples:

=SLOPE(I44:I47,H44:H47) adjacent ranges, works fine.

=SLOPE((H44:H45,H47:H48),(I44:I45,I47:I48)) nonadjacent ranges, doesn't work, returns #VALUE!

I know I can plot these same nonadjacent ranges (using a scatter plot graph) and get the slope and intercept from a trendline on the plot, but it would really help me to be able to have these values (slope and intercept) available directly in my worksheet.

Any help would be greatly appreciated.
 

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