I have a list of locations, with their coordinates, and I have a set of regions of which I have the coordinates of the border points. Now I would like excel to specify for me in what region every location is.
I was thinking of using a nested IF function, but I have up to 20 regions so I am hoping there may be an easier way to do this.
For example:
<colgroup><col><col><col span="4"></colgroup><tbody>
</tbody>
So if C2 falls between C5 and E5, AND D2 falls between D5 and F5, I want it to tell me region 1.
Else if C2 falls between C6 and E6, AND D2 falls between D6 and F6, I want it to tell me region 2, etc.
Is there any function that can do this more easily?
I was thinking of using a nested IF function, but I have up to 20 regions so I am hoping there may be an easier way to do this.
For example:
A | B | C | D | E | F |
1 | location | N | E | ||
2 | location 1 | 51,2088 | 5,995877 | ||
3 | |||||
4 | name | top | left | bottom | right |
5 | region 1 | 51,068352 | 5,661775 | 50,745750 | 6,054801 |
6 | region 2 | 51,561538 | 5,823070 | 51,068352 | 5,661775 |
7 | region 3 | 51,561538 | 5,201854 | 51,068352 | 5,823070 |
<colgroup><col><col><col span="4"></colgroup><tbody>
</tbody>
So if C2 falls between C5 and E5, AND D2 falls between D5 and F5, I want it to tell me region 1.
Else if C2 falls between C6 and E6, AND D2 falls between D6 and F6, I want it to tell me region 2, etc.
Is there any function that can do this more easily?