New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

tiger-boundaries

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tiger-boundaries

Utilities for generating more JavaScript-friendly formats from U.S. Census Bureau Cartographic Boundary Shapefiles

latest
Source
npmnpm
Version
2.0.1
Version published
Maintainers
1
Created
Source

tiger-boundaries

Node package and command line tool for generating GeoJSON from U.S. Census Bureau Cartographic Boundary Shapefiles.

At it's bare bones, it downloads the counties shapefile, converts it to GeoJSON and (optionally) filters the counties to a particular state.

This is designed to be called from an npm script to help build data for other packages.

Installation

npm install https://github.com/ghing/census-boundaries

Get GeoJSON of counties

API

var getCountyGeoJSON = require('tiger-boundaries').getCountyGeoJSON;

getCountyGeoJSON('500k', ['IA'], function(err, data) {
  console.log(JSON.stringify(data));
});

Command Line

countyjson 500k --state IA > iowa.json

Get GeoJSON of congressional districts

API

var getCongressionalDistrictGeoJSON = require('tiger-boundaries').getCongressionalDistrictGeoJSON;

getCongressionalDistrictGeoJSON('500k', '114', ['IL'], function(err, data) {
  console.log(JSON.stringify(data));
});

Command Line

cdjson 500k 114 --state IL > cd_illinois.json

Keywords

census

FAQs

Package last updated on 17 Mar 2021

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