Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

interior

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

interior

  • 0.9.2
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Interior Travis CI Status

Township GeoCoder Web Service

Interior uses the GeoCommunicator GeoCoder Web Service provided by the [US Department of the Interior] 1. For detailed documentation on the web service API, consult the [Methods, Parameters, and Results PDF] 2.

Usage: Get Latitude / Longitude

Given township 1N, range 1E, section 35, and meridian 14 (Gila-Salt Meridian in the US Meridian table), we can get the center point latitude and longitude in the state of Arizona with:

require 'interior'
response = Interior::Geocoder.get_lat_lon('AZ', 14, 1, 'N', 1, 'E', 35)
response.success?   => true
response.latitude   => 33.384549272498
response.longitude  => -112.228362739723

Usage Map 1

Section is option. If omitted, the centerpoint latitude and longitude will be for the township and range:

require 'interior'
response = Interior::Geocoder.get_lat_lon('AZ', 14, 1, 'N', 1, 'E') # no section
response.success?   => true
response.latitude   => 33.4211630233451
response.longitude  => -112.254699834217

Usage Map 2

Usage: Get Meridians

For a collection of all meridians in Arizona:

require 'interior'
meridians = Interior::Geocoder.get_meridians('AZ')
meridians.inspect
  => [ { :name => 'Gila-Salt River', :id => 14 },
       { :name => 'Navajo',          :id => 22 },
       { :name => 'San Bernardino',  :id => 27 } ]

US Meridian Map

The US is divided into several meridians. A [larger map] 3 and table are available for reference.

USA Meridians

US Meridian Table

Each meridian has a corresponding numeric key mapping:

StateMeridianCodeStateMeridianCode
ALHuntsville16ALSt. Stephens25
ALTallahasee29AR5th05
AZGila-Salt River14AZNavajo22
AZSan Bernardino27CAGila-Salt River14
CAHumboldt15CAMount Diablo21
CASan Bernardino27CO6th06
CONew Mex23COUte31
FLTallahasee29IA5th05
IDBoise08IL2nd02
IL3rd03IL4th Illinois04
IN1st01IN2nd02
KS6th06LALouisiana18
LASt. Helena24MIMichigan19
MN5th05MN4th46
MO5th05MSChickasaw09
MSChoctaw10MSHuntsville16
MSSt. Stephens25MSWashington32
MTPrin20ND5th05
NE6th06NMNew Mex23
NVMount Diablo21NVSan Bernardino27
OH1st01OHMichigan19
OHOhio River Survey35OHBetween the Miamis36
OHMuskingum River Basin37OHOhio River Basin38
OH1st Scioto River Base39OH2nd Scioto River Base40
OH3rd Scioto River Base41OHTwelve Mile Square43
OHWest of Great Miami47OHUS Military Survey48
OHCt West Res91OHOhio CO Pur92
OHVa Military Survey93OKCimarron11
OKIndian17ORWillamette33
SD5th05SD6th06
SDBlack Hills07UTSalt Lake26
UTUintah Spec30WAWillamette33
WI4th46WY6th06
WYWind River34

FAQs

Package last updated on 21 Jan 2012

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc