Skip to content

Instantly share code, notes, and snippets.

View alexchinco's full-sized avatar

Alex Chinco alexchinco

View GitHub Profile
<!DOCTYPE html>
<html>
<meta name="viewport" content="width=device-width">
<head>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
<script type="text/javascript" src="http://cdn.mathjax.org/mathjax/2.1-latest/MathJax.js?config=TeX-AMS-MML_SVG-full"></script>
<style type="text/css">
body {
font: 12px serif;
<!DOCTYPE html>
<html>
<meta name="viewport" content="width=device-width">
<head>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
<style type="text/css">
svg { font: 12px serif; }
@alexchinco
alexchinco / binom-approx-to-normal.R
Created September 20, 2013 21:42
Code simulating the accuracy of the binomial approximation to the normal distribution via Berry-Esseen.
## Prep workspace
rm(list=ls())
library(foreign)
library(grid)
library(plyr)
library(ggplot2)
library(tikzDevice)
library(reshape)
library(vars)
library(scales)
@alexchinco
alexchinco / plot--corrected-lambda-estimate--simulated-data--24jan2016.R
Created January 24, 2016 22:43
Create plots for blog post on the characteristic scale of house-price variation.
###########################################################################
###########################################################################
## @purpose: Estimate corrected lambda in simulated data.
## ------------------------------------------------------------------------
## @author: Alex Chinco
## @date: 24-JAN-2016
###########################################################################
###########################################################################
###########################################################################
@alexchinco
alexchinco / plot--investors-and-supply-constraint--11jun2016.R
Created June 24, 2016 16:04
Create figure for blog post: "Investor Holdings, Naïve Beliefs, and Artificial Supply Constraints"
###########################################################################
###########################################################################
## @purpose: Plot supply constraint imposed by investors purchases.
## ------------------------------------------------------------------------
## @author: Alex Chinco
## @date: 11-JUN-2016
###########################################################################
###########################################################################
###########################################################################
@alexchinco
alexchinco / plot--inferring-horizon-from-volume--12jul2016.R
Created July 13, 2016 14:35
Code for blog post on inferring traders' investment horizons from aggregate trading volume.
###########################################################################
###########################################################################
## @purpose: Verify that the wavelet-variance estimator picks up traders'
## investment horizons in simulated data.
## ------------------------------------------------------------------------
## @author: Alex Chinco
## @date: 12-JUL-2016
###########################################################################
###########################################################################
@alexchinco
alexchinco / Mortgage Math.carbide.md
Last active September 7, 2016 15:47
Mortgage Math

Mortgage Math

@alexchinco
alexchinco / Refinancing Decision.carbide.md
Last active September 7, 2016 15:47
Refinancing Decision

Refinancing Decision

@alexchinco
alexchinco / Intuition Behind the "Bayesian LASSO".carbide.md
Last active September 23, 2016 19:06
Intuition Behind the "Bayesian LASSO"

Intuition Behind the "Bayesian LASSO"

@alexchinco
alexchinco / plot--bayesian-lasso-intuition--24sep2016.R
Created September 24, 2016 18:31
Intuition Behind the Bayesian LASSO
## ##########################################################################################################################
## ##########################################################################################################################
## @purpose: Create plots to show intuition behind the bayesian lasso in park and casella (2008).
## --------------------------------------------------------------------------------------------------------------------------
## @author: Alex Chinco
## @date: 24-SEP-2016
## ##########################################################################################################################
## ##########################################################################################################################