PC Pals Forum

Technical Help & Discussion => Windows PCs & Software: Help, News & Discussion => Topic started by: DJ on March 20, 2005, 13:06

Title: Calculate Range in Excel
Post by: DJ on March 20, 2005, 13:06
Hi Folks,

I'm in the middle of a uni assignment and need to calculate the range from a collection of numbers.

For example (this is over simplified)...

If I had the numbers 10,15 and 20 in cells A1 > C1  the range would be 10.

How do I calculate this automatically in Excel. I tried

Code: [Select]

=range(A1:C1)


but it doesn't work.  :roll:

Anyone know the correct function to use?

Thanks  :wink:

DJ
Title: Calculate Range in Excel
Post by: DJ on March 20, 2005, 14:11
Its ok, I've worked out a workaround...

Code: [Select]

=(max(A1:C1))-(min(A1:C1))


Still interested if theres an easier way of doing it though!

DJ
Title: Calculate Range in Excel
Post by: TR on March 20, 2005, 14:42
=SUM(A1:C1)
Might have read your Question wrong  :roll:
Title: Calculate Range in Excel
Post by: DJ on March 20, 2005, 16:17
Thanks TR, but that would give an answer of 45.

I'm looking to calculate the range (difference) between the set of numbers. The highest number minus the lowest number (but they're not in any sort of order).

DJ
Title: Calculate Range in Excel
Post by: TR on March 20, 2005, 16:58
DJ

Use the "if" command in the calc.
Title: Re: Calculate Range in Excel
Post by: TR on March 20, 2005, 17:18
COUNTIF will probaly work using the < les than command.