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
""" | |
DataFrameTable | |
============== | |
Quick and Dirty Qt app to view pandas DataFrames. Includes sorting and | |
filterting. | |
Based on qtpandas in pandas sandbox module, by Jev Kuznetsov | |
Usage: |
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 multiRegExOr(term_list): | |
"""Returns a singles string of "OR"ed regex terms from a given list. | |
Parameters | |
---------- | |
term_list: list | |
List of regular expressions. | |
Returns | |
------- |
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
%env BOKEH_RESOURCES=inline ipython notebook | |
from bokeh.io import show, output_notebook | |
from bokeh.plotting import ColumnDataSource, figure | |
from bokeh.models import HoverTool, Range1d | |
output_notebook() | |
fig = figure(tools=[HoverTool(tooltips=[("html", "@html{safe}")])]) | |
fig.quad(left="left", top="top", bottom="bottom", right="right", | |
source=ColumnDataSource({"left": [1,3], "bottom": [1,3], |
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
# -*- coding: utf-8 -*- | |
""" | |
LICENSE: BSD (same as pandas) | |
example use of pandas with oracle mysql postgresql sqlite | |
- updated 9/18/2012 with better column name handling; couple of bug fixes. | |
- used ~20 times for various ETL jobs. Mostly MySQL, but some Oracle. | |
to do: | |
save/restore index (how to check table existence? just do select count(*)?), | |
finish odbc, |
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 datetime import datetime | |
from ipywidgets import widgets | |
from dominate import tags | |
def timestamp(): | |
"""Return a ipywidget timestamp.""" | |
ts = tags.h4("{:%I:%M:%S %p %A %B %d %Y}".format(datetime.now())) | |
ts_widget = widgets.HTML(ts.render()) | |
return ts_widget |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer