Skip to content

Instantly share code, notes, and snippets.

@darribas
darribas / cont_block.ipynb
Last active August 29, 2015 14:01
Contiguity and block -based weights in PySAL
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@darribas
darribas / .gitignore
Last active April 26, 2016 05:44
London boroughs, one by one
*.swp
*~
.ipynb_checkpoints/
@darribas
darribas / geo_postcard.ipynb
Created August 11, 2014 03:51
(Geo-)postcard from Chicago
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@darribas
darribas / pred_prob.py
Created September 15, 2014 17:20
Predictions in a probit
import numpy as np
import pandas as pd
import statsmodels.api as sm
from scipy.stats import norm as N
n, k = 1000, 2
x = np.random.random((n, k+1))
x[:, 0] = 1
b = np.ones((k+1, ))
e = np.random.normal(size=(n, ))
@darribas
darribas / pdf2handout
Created October 7, 2014 17:40
pdf2handout
#!/usr/bin/python
import os, sys
args = sys.argv
if len(args) > 1:
inpath = args[1]
if len(args)==2:
outpath = inpath.replace('.pdf', '_handout.pdf')
@darribas
darribas / .gitignore
Last active August 29, 2015 14:08
PySAL-R benchmarking
.ipynb_checkpoints
*.pyc
*.swp
@darribas
darribas / .gitignore
Last active April 1, 2024 18:45
LISA cluster maps with `PySAL`
.ipynb_checkpoints/
@darribas
darribas / main_effect_plots.ipynb
Created July 17, 2015 15:05
Main Effect Plots
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@darribas
darribas / pandas_dask_test.ipynb
Created July 27, 2015 17:04
Quick comparison between `pandas` and `dask` groupby functionality.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
set nocompatible " be iMproved, required
filetype off " required
"set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required