For continuous data such as time series, a streamgraph can be used in place of stacked bars. This example also demonstrates path transitions to interpolate between different layouts. Streamgraph algorithm, colors, and data generation inspired by Byron and Wattenberg.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Node(object): | |
def __init__(self, name, lc=None, rc=None): | |
self.name = name | |
self.lc = lc | |
self.rc = rc | |
self.rn = None | |
# THE MEAT OF THE PROBLEM | |
@staticmethod | |
def link_rn(level_list): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def list_condense(l): | |
run_start = None | |
in_run = False | |
last_item = None | |
out = '' | |
while len(l): | |
item = l.pop(0) | |
if not in_run: | |
run_start = item |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.pie_arc { | |
font-size: 0.75em; | |
} | |
.distillery { | |
font-weight: bold; | |
} | |
#svg { | |
text-align: center; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module pipeRegister(clk, reset, | |
stall, | |
regWrEnIn, memWrEnIn, mulSelIn, aluOutIn, PCIn, instrTypeIn, isBranchTakenIn, | |
regWrEnOut, memWrEnOut, mulSelOut, aluOutOut, PCOut, instrTypeOut, isBranchTakenOut | |
); | |
parameter BIT_WIDTH = 32; | |
input clk, reset; | |
input stall; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
local function difference(after, before) | |
return after - before | |
end | |
local function hms(seconds) | |
local hours = floor(seconds / 3600) | |
local minutes = floor((seconds % 3600) / 60) | |
local sec = floor(seconds % 60) | |
return hours, minutes, sec | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 49f5b2cb90dba546fc93e045311cf9f1d273050d Mon Sep 17 00:00:00 2001 | |
From: Tim Martin <tim@timmart.in> | |
Date: Sat, 17 Jan 2015 02:15:01 -0500 | |
Subject: [PATCH] fix coloring on urxvt | |
--- | |
colors/hybrid.vim | 6 +++--- | |
1 file changed, 3 insertions(+), 3 deletions(-) | |
diff --git a/colors/hybrid.vim b/colors/hybrid.vim |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from operator import mul | |
from functools import reduce | |
from itertools import permutations | |
def factorial(n): | |
return reduce(mul, range(1,n+1), 1) | |
def word_index(word): | |
index = 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MeteredSession(requests.Session): | |
""" | |
Creates a session where response downloads are shown graphically on the | |
terminal with `click.progressbar` meters. This session adds a hook to | |
responses that will attach 2 meter methods, described below. | |
To use these meter methods on a response obj `resp`, call | |
* `resp.iter_content_metered(chunk_size, label='\t' + resp.url)` | |
* `resp.consume_content_metered(chunk_size, label='\t' + resp.url)` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From a9a78aa85012d4ef5bd25ebf74292268a5f90d00 Mon Sep 17 00:00:00 2001 | |
From: Tim Martin <tim.martin@gatech.edu> | |
Date: Sun, 27 Jun 2010 01:44:24 -0400 | |
Subject: [PATCH] mammoths will not be chosen when mounting in capitals | |
--- | |
GoGoMount.lua | 21 +++++++++++++++++++++ | |
GoGoMountData.lua | 38 +++++++++++++++++++------------------- | |
2 files changed, 40 insertions(+), 19 deletions(-) |
OlderNewer