GitHub - mbloch/mapshaper: Tools for editing Shapefile, GeoJSON, TopoJSON and CSV files Skip to content Sign up Why GitHub? Features → Mobile → Actions → Codespaces → Packages → Security → Code review → Project management → Integrations → GitHub Sponsors → Customer stories → Security → Team Enterprise Explore Explore GitHub → Learn & contribute Topics → Collections → Trending → Learning Lab → Open source guides → Connect with others The ReadME Project → Events → Community forum → GitHub Education → GitHub Stars program → Marketplace Pricing Plans → Compare plans → Contact Sales → Nonprofit → Education → In this repository All GitHub ↵ Jump to ↵ No suggested jump to results In this repository All GitHub ↵ Jump to ↵ In this user All GitHub ↵ Jump to ↵ In this repository All GitHub ↵ Jump to ↵ Sign in Sign up {{ message }} mbloch / mapshaper Watch 131 Star 2.5k Fork 410 Tools for editing Shapefile, GeoJSON, TopoJSON and CSV files mapshaper.org View license 2.5k stars 410 forks Star Watch Code Issues 77 Pull requests 4 Actions Projects 0 Wiki Security Insights More Code Issues Pull requests Actions Projects Wiki Security Insights master 4 branches 287 tags Go to file Code Clone HTTPS GitHub CLI Use Git or checkout with SVN using the web URL. Work fast with our official CLI. Learn more. Open with GitHub Desktop Download ZIP Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Go back Launching GitHub Desktop If nothing happens, download GitHub Desktop and try again. Go back Launching Xcode If nothing happens, download Xcode and try again. Go back Launching Visual Studio If nothing happens, download the GitHub extension for Visual Studio and try again. Go back Latest commit mbloch v0.5.30 … 89a7699 Jan 22, 2021 v0.5.30 89a7699 Git stats 2,505 commits Files Permalink Failed to load latest commit information. Type Name Latest commit message Commit time bin Fix saving to subdirectories with mapshaper-gui Jul 21, 2020 src v0.5.30 Jan 22, 2021 test v0.5.30 Jan 22, 2021 www Add -classify and -colors commands Jan 21, 2021 .gitignore Refactored codebase to use ES modules Apr 12, 2020 .travis.yml Fix travis config by building project before running tests Apr 16, 2020 CHANGELOG.md v0.5.30 Jan 22, 2021 LICENSE Update README, add MPL 2.0 license Jul 5, 2013 README.md add user-contributed resourced to readme Dec 27, 2019 package-lock.json v0.5.30 Jan 22, 2021 package.json v0.5.30 Jan 22, 2021 rollup.config.js Really fix rollup config Apr 16, 2020 View code README.md Mapshaper Introduction Mapshaper is software for editing Shapefile, GeoJSON, TopoJSON, CSV and several other data formats, written in JavaScript. Mapshaper supports essential map making tasks like simplifying shapes, editing attribute data, clipping, erasing, dissolving, filtering and more. See the project wiki for documentation on how to use mapshaper. To suggest improvements, add an issue. Command line tools Mapshaper includes several command line programs, which can be run under Mac OS X, Linux and Windows. mapshaper Runs mapshaper commands. mapshaper-xl Works the same as mapshaper, but runs with more RAM to support larger files. mapshaper-gui Runs the mapshaper Web interface locally. The project wiki has an introduction to using the command line tool that includes many simple examples. For a detailed reference, see the Command Reference. Interactive web interface Visit the public website at www.mapshaper.org or use the web UI locally via the mapshaper-gui script. All processing is done in the browser, so your data stays private, even when using the public website. The web UI works in recent desktop versions of Chrome, Firefox, Safari and Internet Explorer. Safari before v10.1 and IE before v10 are not supported. User-contributed resources rmapshaper is an R package written by Andy Teucher that gives R users access to many of mapshaper's editing commands. Here are resources for using mapshaper with Docker, provided by Christian Weiss. You can find a number of mapshaper tutorials online, including a two part guide to command line cartography by Dylan Moriarty and this introduction by Jack Dougherty. Large file support Web interface Firefox is able to load Shapefiles and GeoJSON files larger than 1GB. Chrome has improved in recent versions, but is still prone to out-of-memory errors when importing files larger than several hundred megabytes. Command line interface There are hard limits for reading and writing most file types. The maximum output size of a single file of any type is 2GB. Some file types (GeoJSON, CSV, .shp) are read incrementally, so much larger files can be imported. When working with very large files, mapshaper may become unresponsive or crash with the message "JavaScript heap out of memory." One option is to run mapshaper-xl, which allocates more memory than the standard mapshaper program (8GB by default). Starting with version 0.4.131, you can specify the amount of memory to allocate like this: mapshaper-xl 20gb [commands]. Another solution is to run Node directly with the --max-old-space-size option. The following example (Mac or Linux) allocates 16GB of memory: $ node --max-old-space-size=16000 `which mapshaper` Installation Mapshaper requires Node.js. With Node installed, you can install the latest release version of mapshaper using npm. Install with the "-g" flag to make the executable scripts available systemwide. npm install -g mapshaper To install and run the latest development code from github: git clone git@github.com:mbloch/mapshaper.git cd mapshaper npm install # install dependencies npm run build # bundle source code files npm link # (optional) add global symlinks so scripts are available systemwide Building and testing From the project directory, run npm run build to build both the cli and web UI modules. Run npm test to run mapshaper's tests. License This software is licensed under MPL 2.0. According to Mozilla's FAQ, "The MPL's ‘file-level’ copyleft is designed to encourage contributors to share modifications they make to your code, while still allowing them to combine your code with code under other licenses (open or proprietary) with minimal restrictions." Acknowledgements My colleagues at The New York Times, for countless suggestions, bug reports and general helpfulness. Mark Harrower, for collaborating on the original "MapShaper" program at the University of Wisconsin–Madison. About Tools for editing Shapefile, GeoJSON, TopoJSON and CSV files mapshaper.org Topics svg topojson csv geojson gis shapefile Resources Readme License View license Releases 287 v0.5.30 Latest Jan 22, 2021 + 286 releases Packages 0 No packages published Used by 220 + 212 Contributors 6 Languages JavaScript 98.9% Other 1.1% © 2021 GitHub, Inc. Terms Privacy Security Status Docs Contact GitHub Pricing API Training Blog About You can’t perform that action at this time. You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.