{ "metadata": { "name": "", "signature": "sha256:356c91d14531311d76c1ff145ea33c89dd841f5079cd41956b4890e716034964" }, "nbformat": 3, "nbformat_minor": 0, "worksheets": [ { "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "- [Color Brewer Sequential](#Color-Brewer-Sequential)\n", "- [Color Brewer Diverging](#Color-Brewer-Diverging)\n", "- [Color Brewer Qualitative](#Color-Brewer-Qualitative)\n", "- [Wes Anderson](#Wes-Anderson)" ] }, { "cell_type": "code", "collapsed": false, "input": [ "from brewer2mpl import qualitative, sequential, diverging, wesanderson\n", "from brewer2mpl.brewer2mpl import _ColorMap" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 7 }, { "cell_type": "code", "collapsed": false, "input": [ "def display_maps(module):\n", " for k in dir(module):\n", " thing = getattr(module, k)\n", " if isinstance(thing, dict) and 'max' in thing:\n", " thing = thing['max']\n", " if isinstance(thing, _ColorMap):\n", " print(k)\n", " thing.show_as_blocks()" ], "language": "python", "metadata": {}, "outputs": [], "prompt_number": 21 }, { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Color Brewer Sequential" ] }, { "cell_type": "code", "collapsed": false, "input": [ "display_maps(sequential)" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Blues\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "BuGn\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "BuPu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "GnBu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Greens\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Greys\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "OrRd\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Oranges\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PuBu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PuBuGn\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PuRd\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Purples\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "RdPu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Reds\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "YlGn\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "YlGnBu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "YlOrBr\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "YlOrRd\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] } ], "prompt_number": 22 }, { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Color Brewer Diverging" ] }, { "cell_type": "code", "collapsed": false, "input": [ "display_maps(diverging)" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "BrBG\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PRGn\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PiYG\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "PuOr\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "RdBu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "RdGy\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "RdYlBu\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "RdYlGn\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Spectral\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] } ], "prompt_number": 23 }, { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Color Brewer Qualitative" ] }, { "cell_type": "code", "collapsed": false, "input": [ "display_maps(qualitative)" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Accent\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Dark2\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Paired\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Pastel1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Pastel2\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Set1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Set2\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Set3\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] } ], "prompt_number": 24 }, { "cell_type": "heading", "level": 1, "metadata": {}, "source": [ "Wes Anderson" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "Via http://wesandersonpalettes.tumblr.com/." ] }, { "cell_type": "code", "collapsed": false, "input": [ "display_maps(wesanderson)" ], "language": "python", "metadata": {}, "outputs": [ { "output_type": "stream", "stream": "stdout", "text": [ "Cavalcanti\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Chevalier\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Darjeeling1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "FantasticFox1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "GrandBudapest1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Margot1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Margot2\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Mendl\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Moonrise1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Moonrise2\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Moonrise3\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Moonrise4\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Royal1\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] }, { "output_type": "stream", "stream": "stdout", "text": [ "Zissou\n" ] }, { "html": [ "
" ], "metadata": {}, "output_type": "display_data", "text": [ "" ] } ], "prompt_number": 11 }, { "cell_type": "code", "collapsed": false, "input": [], "language": "python", "metadata": {}, "outputs": [] } ], "metadata": {} } ] }