A set of useful chart functions using D3