I'm trying to find a formula to return a value that represents the count of intervals at a certain increment size within a range. For example:
<tbody>
</tbody>Rules:
The returned value must include the starting point "FROM" value as a count of one interval.
If the "TO" rule is not evenly divisible by the "BY" increment, the last interval point inside of the range is counted. For example, in a range of 10 to 30 at increments of 3, the last possible point is at 28:
If it is evenly divisible, obviously the end of the range is included (30, if the range was 10 to 30 by 2).
10 to 30 by 3:
10
13
16
19
22
25
28
For a count of 7.
It is the count that I'm trying to write a formula for.
Any ideas?
RULE | FROM | TO | BY |
1 | 12 | 90 | 6 |
2 | 2 | 5 | 1.75 |
2 | 4 | 50 | 3 |
<tbody>
</tbody>
The returned value must include the starting point "FROM" value as a count of one interval.
If the "TO" rule is not evenly divisible by the "BY" increment, the last interval point inside of the range is counted. For example, in a range of 10 to 30 at increments of 3, the last possible point is at 28:
If it is evenly divisible, obviously the end of the range is included (30, if the range was 10 to 30 by 2).
10 to 30 by 3:
10
13
16
19
22
25
28
For a count of 7.
It is the count that I'm trying to write a formula for.
Any ideas?
Last edited: