Skip to content

Instantly share code, notes, and snippets.

View muziejus's full-sized avatar

Moacir P. de Sá Pereira muziejus

View GitHub Profile

This is an h1

This is a paragraph.

@muziejus
muziejus / crashing_point.geojson
Created November 16, 2017 01:02
Crashing geojson on turf
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@muziejus
muziejus / markdown-cheat-sheet.md
Created August 22, 2017 15:59
Markdown Cheat Sheet
tags author date title
these
are
some
tags
Moacir P. de Sá Pereira
2017-07-07
Markdown Cheat Sheet

Markdown Cheat Sheet headline

Regular text (subhead)

@muziejus
muziejus / gist:bf0222ff5ac1a24bbee5e5eac9622c00
Created September 22, 2016 03:51
Getting Stanford NER up and running on DHBox
#! /bin/sh
# This is a barebones and super brittle script by Moacir P. de Sá Pereira
# (@muziejus on GitHub) for installing part of the Stanford NLP library to a
# DHBox (http://dhbox.org)
# First, we need to upgrade Java
# from: http://stackoverflow.com/questions/30177455/moving-from-jdk-1-7-to-jdk-1-8-on-ubuntu
# Newer versions of java *are* available
@muziejus
muziejus / create_citibike_geojson.rb
Created February 6, 2016 05:20
Make a geojson file out of the app dump for CitiBike locations
# citibike stations: http://appservices.citibikenyc.com/v1/station/list
# Save this json file as "citibikestations.json"
# The result is a file called "citibikestations.geojson," which Qgis will read with no trouble. Leaflet too.
require 'json'
bike_stations = JSON.parse(File.read('citibikestations.json'))
geojson_array = bike_stations["results"].map do |p|
{ "type" => "Feature",
"geometry" => {
"type" => "Point",
"coordinates" => [p["longitude"], p["latitude"]]