Help with a Latitude Longitude lookup required!

plotboxmark

New Member
Joined
Dec 9, 2015
Messages
4
Hi

I was hoping someone could give me some assistance with a query I have to complete for a mapping project. I have calculated out the Grid intersections of a theoretical grid compared to true Latitude and Longitude co-ordinates:

Grid LAT LONG
A137.8769569-122.5262497
A237.87692395-122.5262488
A337.876891-122.5262479
A437.87685806-122.526247
A537.87682511-122.5262461
A637.87679216-122.5262452
A737.87675921-122.5262443
A837.87672626-122.5262434
A937.87669332-122.5262425
A1037.87666037-122.5262416
A1137.87662742-122.5262407

<tbody>
</tbody>

The intersection is via the Top Left hand corner of the Grid square, and Alphas run Left to Right from A to CS, and Numerics run Up to Down from 1 to 180.

I then have a table of specific points known by Lat/Long that I need to reference to the Grid that the point lands in. The table of known points is around 7000 points long.

Is there a way I could lookup the Latitude value (which may throw back multiple rows with a value that matches between its starting value and the next cell starting value), and at the same time lookup the Longitude values for the same, but only return a result that matches both?

Its confusing me, hence the slightly awkwardly posed question, but any help would be great

Thanks
 

Excel Facts

Select a hidden cell
Somehide hide payroll data in column G? Press F5. Type G1. Enter. Look in formula bar while you arrow down through G.
If I understand correctly, you wish to look up the LAT and LONG figures and if there is an exact match in the giant list then report the appropriate grid.

I think this might un-furrow your brow:

ABCDEFG
1GridLATLONGquery (LAT and LONG)Grid
2A137.8769569-122.526249737.876891-122.5262479A3
3A237.87692395-122.5262488
4A337.876891-122.5262479
5A437.87685806-122.526247
6A537.87682511-122.5262461
7A637.87679216-122.5262452
8A737.87675921-122.5262443
9A837.87672626-122.5262434
10A937.87669332-122.5262425
11A1037.87666037-122.5262416
12A1137.87662742-122.5262407

<colgroup><col style="width: 25pxpx"><col><col><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet19

Array Formulas
CellFormula
G2{=IFERROR(INDEX(A2:A12,MATCH(E2&F2,B2:B12&C2:C12,0)),"No Match")}

<thead>
</thead><tbody>
</tbody>
Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself

<tbody>
</tbody>
 
Upvote 0
If I understand correctly, you wish to look up the LAT and LONG figures and if there is an exact match in the giant list then report the appropriate grid.

I think this might un-furrow your brow:

ABCDEFG
1GridLATLONGquery (LAT and LONG)Grid
2A137.8769569-122.526249737.876891-122.5262479A3
3A237.87692395-122.5262488
4A337.876891-122.5262479
5A437.87685806-122.526247
6A537.87682511-122.5262461
7A637.87679216-122.5262452
8A737.87675921-122.5262443
9A837.87672626-122.5262434
10A937.87669332-122.5262425
11A1037.87666037-122.5262416
12A1137.87662742-122.5262407

<tbody>
</tbody>
Sheet19

Array Formulas
CellFormula
G2{=IFERROR(INDEX(A2:A12,MATCH(E2&F2,B2:B12&C2:C12,0)),"No Match")}

<tbody>
</tbody>
Entered with Ctrl+Shift+Enter. If entered correctly, Excel will surround with curly braces {}.
Note: Do not try and enter the {} manually yourself

<tbody>
</tbody>


Thanks for your assistance, and that looks like its almost cracked it, but there is an added layer of complexity, as the Latitude and longitudes are not exact matches in the table as compared with the points we are looking up. So I know that the Latitude for instance could be in say 20 separate grid locations, and the longitude could be in 20 different grid locations, but only 1 grid reference will be in both lists of matched grid references.

Can you think of an additional layer of referencing formula that could assist?

So far, you have helped greatly and I really appreciate your time and help!
 
Upvote 0

Forum statistics

Threads
1,215,032
Messages
6,122,770
Members
449,095
Latest member
m_smith_solihull

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top