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
{"label":"root","blocks":[{"label":"","type":"latch","id":1,"inputs":[{"name":"in","value":null,"type":"any"},{"name":"ctrl","value":null,"type":"boolean"}],"outputs":[{"name":"true","type":"any"},{"name":"false","type":"any"}],"source":null,"position":{"x":358,"y":348}},{"label":"","type":"first","id":2,"inputs":[{"name":"in","value":null,"type":"any"}],"outputs":[{"name":"first","type":"boolean"}],"source":null,"position":{"x":249,"y":417}},{"label":"","type":"identity","id":4,"inputs":[{"name":"in","value":{"data":0},"type":"any"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":147,"y":320}},{"label":"","type":"delay","id":10,"inputs":[{"name":"in","value":{"data":true},"type":"any"},{"name":"duration","value":{"data":"1s"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":367,"y":544}},{"label":"","type":"gate","id":11,"inputs":[{"name":"in","value":null,"type":"any"},{"name":"ctrl","value":null,"type":"any"}],"outputs":[{"name":"out","type":"an |
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
{"label":"root","blocks":[{"label":"","type":"exponential","id":1,"inputs":[{"name":"rate","value":{"data":1},"type":"number"}],"outputs":[{"name":"draw","type":"number"}],"source":null,"position":{"x":263,"y":345}},{"label":"","type":"delay","id":2,"inputs":[{"name":"in","value":{"data":1},"type":"any"},{"name":"duration","value":null,"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":578,"y":330}},{"label":"","type":"toString","id":4,"inputs":[{"name":"in","value":null,"type":"any"}],"outputs":[{"name":"out","type":"string"}],"source":null,"position":{"x":387,"y":345}},{"label":"","type":"concat","id":5,"inputs":[{"name":"a","value":null,"type":"string"},{"name":"b","value":{"data":"s"},"type":"string"}],"outputs":[{"name":"a+b","type":"string"}],"source":null,"position":{"x":486,"y":345}},{"label":"","type":"log","id":9,"inputs":[{"name":"log","value":null,"type":"any"}],"outputs":[],"source":null,"position":{"x":713,"y":330}}],"connections":[{"from":{"id":2,"route":0}, |
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
{"label":"root","blocks":[{"label":"","type":"latch","id":2,"inputs":[{"name":"in","value":null,"type":"any"},{"name":"ctrl","value":null,"type":"boolean"}],"outputs":[{"name":"true","type":"any"},{"name":"false","type":"any"}],"source":null,"position":{"x":794,"y":227}},{"label":"","type":"gate","id":4,"inputs":[{"name":"in","value":null,"type":"any"},{"name":"ctrl","value":null,"type":"any"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":426,"y":228}},{"label":"ticker","type":"delay","id":1,"inputs":[{"name":"in","value":{"data":"boo"},"type":"any"},{"name":"duration","value":{"data":"1s"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":490,"y":371}},{"label":"","type":"+","id":14,"inputs":[{"name":"x","value":null,"type":"number"},{"name":"y","value":{"data":1},"type":"number"}],"outputs":[{"name":"x+y","type":"number"}],"source":null,"position":{"x":433,"y":106}},{"label":"","type":"identity","id":10,"inputs":[{"name":"in","value":{"data":0}, |
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
{"label":"root","blocks":[{"label":"","type":"delay","id":13,"inputs":[{"name":"in","value":{"data":2},"type":"any"},{"name":"duration","value":{"data":"2s"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":226,"y":272}},{"label":"","type":"log","id":16,"inputs":[{"name":"log","value":null,"type":"any"}],"outputs":[],"source":null,"position":{"x":777,"y":190}},{"label":"","type":"delay","id":3,"inputs":[{"name":"in","value":{"data":1},"type":"any"},{"name":"duration","value":{"data":"1s"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":221,"y":159}},{"label":"","type":"set","id":22,"inputs":[{"name":"key","value":{"data":"top"},"type":"string"},{"name":"value","value":null,"type":"any"}],"outputs":[{"name":"object","type":"object"}],"source":null,"position":{"x":474,"y":146}},{"label":"","type":"set","id":23,"inputs":[{"name":"key","value":{"data":"bottom"},"type":"string"},{"name":"value","value":null,"type":"any"}],"outputs":[{"n |
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
{"label":"splitting","blocks":[{"label":"","type":"get","id":2,"inputs":[{"name":"in","value":null,"type":"object"},{"name":"key","value":{"data":"a"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":901,"y":393}},{"label":"","type":"delay","id":1,"inputs":[{"name":"in","value":{"data":{"a":1,"b":2}},"type":"any"},{"name":"duration","value":{"data":"1s"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":692,"y":470}},{"label":"","type":"+","id":11,"inputs":[{"name":"x","value":null,"type":"number"},{"name":"y","value":{"data":1},"type":"number"}],"outputs":[{"name":"x+y","type":"number"}],"source":null,"position":{"x":1031,"y":392}},{"label":"","type":"get","id":3,"inputs":[{"name":"in","value":null,"type":"object"},{"name":"key","value":{"data":"b"},"type":"string"}],"outputs":[{"name":"out","type":"any"}],"source":null,"position":{"x":1193,"y":578}},{"label":"","type":"merge","id":6,"inputs":[{"name":"in","value":null,"type":"objec |
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
{"label":"pubsub","blocks":[{"label":"","type":"endpoint","id":8,"inputs":[{"name":"name","value":{"data":"bob"},"type":"string"}],"outputs":[{"name":"request","type":"object"},{"name":"writer","type":"writer"},{"name":"body","type":"string"}],"source":"server","position":{"x":543,"y":83}},{"label":"","type":"kvSet","id":9,"inputs":[{"name":"key","value":null,"type":"string"},{"name":"value","value":null,"type":"any"}],"outputs":[{"name":"new","type":"boolean"}],"source":"key_value","position":{"x":748,"y":153}},{"label":"","type":"kvDump","id":2,"inputs":[{"name":"dump","value":null,"type":"any"}],"outputs":[{"name":"object","type":"object"}],"source":"key_value","position":{"x":516,"y":465}},{"label":"","type":"sink","id":11,"inputs":[{"name":"in","value":null,"type":"any"}],"outputs":[],"source":null,"position":{"x":916,"y":89}},{"label":"","type":"keys","id":3,"inputs":[{"name":"in","value":null,"type":"object"}],"outputs":[{"name":"keys","type":"array"}],"source":null,"position":{"x":654,"y":589}},{"labe |
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
execute pathogen#infect() | |
syntax on | |
filetype plugin indent on | |
syntax enable | |
colorscheme monokai | |
" indents | |
set tabstop=8 softtabstop=0 expandtab shiftwidth=4 smarttab | |
" backspace |
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
""" | |
tiny script to convert a pandas data frame into a JSON object | |
""" | |
import ujson as json | |
import pandas | |
import numpy as np | |
df = pandas.DataFrame({ | |
"time" : [1,2,3,4,5], |
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
### MATPLOTLIBRC FORMAT | |
### This is a custom config based on huyng's gist: https://gist.github.com/816622 | |
#### CONFIGURATION BEGINS HERE | |
# the default backend; one of GTK GTKAgg GTKCairo CocoaAgg FltkAgg | |
# MacOSX QtAgg Qt4Agg TkAgg WX WXAgg Agg Cairo GDK PS PDF SVG Template | |
# You can also deploy your own backend outside of matplotlib by |
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 __future__ import unicode_literals | |
from urlparse import parse_qs | |
import requests | |
from requests_oauthlib import OAuth1 | |
key = "key" | |
secret ="secret" | |
oauth = OAuth1(key, secret) |
OlderNewer