Skip to content

Instantly share code, notes, and snippets.

@pierrelorioux
pierrelorioux / chart.js
Created November 24, 2015 09:19 — forked from chrtze/chart.js
Line Chart Example
var Chart = (function(window,d3) {
var svg, data, x, y, xAxis, yAxis, dim, chartWrapper, line, path, margin = {}, width, height, locator;
var breakPoint = 768;
d3.csv('data.csv', init); //load data, then initialize chart
//called once the data is loaded
function init(csv) {
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@pierrelorioux
pierrelorioux / README.md
Created September 12, 2015 21:52
French soccer championship replay
@pierrelorioux
pierrelorioux / README.md
Last active September 12, 2015 21:42 — forked from dowstreet/README.md
Connected Particles III
CREATE TABLE images as
SELECT ROWID, "tile_data", tile_row as "tile_id"
FROM "tiles"
ORDER BY ROWID
@pierrelorioux
pierrelorioux / google_sat.xml
Created June 3, 2015 19:59
google sat layer dans MOBAC
<customMapSource>
<name>Google SAT</name>
<minZoom>0</minZoom>
<maxZoom>19</maxZoom>
<tileType>JPG</tileType>
<tileUpdate>IfNoneMatch</tileUpdate>
<url>http://mt{$serverpart}.google.com/vt/lyrs=s,m&amp;hl=iw&amp;x={$x}&amp;y={$y}&amp;z={$z}</url>
<serverParts>0 1 2 3</serverParts>
</customMapSource>
# First:
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.*
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following:
#go to /usr/local/lib and delete any node and node_modules
cd /usr/local/lib
sudo rm -rf node*
------------------------------------------------------------------------------------------------------------------------------
DESCRIPTION:
Notes for deploying TileStream on an AWS EC2 Ubuntu 12.04.2 Server for development. Includes workflow for creating
a local tile cache with TileMill, connecting to your Ubuntu EC2 server via SSH using Mac OSX Terminal, and uploading
your tiles (.mbtiles) to your TileStream server.
REFERENCES:
TileStream git repo: https://github.com/mapbox/tilestream
-----------------------------------------------------------------------------------------------------------------------------
@pierrelorioux
pierrelorioux / Beirut_AirBnb.py
Last active August 29, 2015 14:14
AirBnB scrapping - Washington (page 1 to 56)
# coding=utf-8
from bs4 import BeautifulSoup
import csv
import requests
with open('washington.csv', 'w') as csvfile:
fieldnames = ['flat','url','lat','lon','usr','price_night']
writer = csv.DictWriter(csvfile, delimiter=';',fieldnames=fieldnames)
@pierrelorioux
pierrelorioux / README.md
Last active August 29, 2015 14:06
An aRanger arrangment.

An arrangement of items made through aRanger.