mpl.finance

A collection of functions for collecting, analyzing and plotting financial data. User contributions welcome!

This module is deprecated in 1.4 and will be moved to mpl_toolkits or it’s own project in the future.

Functions

candlestick2_ochl(ax, opens, closes, highs, lows) Represent the open, close as a bar line and high low range as a vertical line.
candlestick2_ohlc(ax, opens, highs, lows, closes) Represent the open, close as a bar line and high low range as a vertical line.
candlestick_ochl(ax, quotes[, width, ...]) Plot the time, open, close, high, low as a vertical line ranging from low to high.
candlestick_ohlc(ax, quotes[, width, ...]) Plot the time, open, high, low, close as a vertical line ranging from low to high.
date2num(d) d is either a datetime instance or a sequence of datetimes.
fetch_historical_yahoo(ticker, date1, date2) Fetch historical data for ticker between date1 and date2.
get_cachedir(*args, **kwargs) Return the location of the cache directory.
index_bar(ax, vals[, facecolor, edgecolor, ...]) Add a bar collection graph with height vals (-1 is missing).
iterable(obj) return true if obj is iterable
md5 Returns a md5 hash object; optionally initialized with a string
mkdirs(newdir[, mode]) make directory newdir recursively, and set mode. Equivalent to
parse_yahoo_historical_ochl(fh[, adjusted, ...]) Parse the historical data in file handle fh from yahoo finance.
parse_yahoo_historical_ohlc(fh[, adjusted, ...]) Parse the historical data in file handle fh from yahoo finance.
plot_day_summary2_ochl(ax, opens, closes, ...) Represent the time, open, close, high, low, as a vertical line ranging from low to high.
plot_day_summary2_ohlc(ax, opens, highs, ...) Represent the time, open, high, low, close as a vertical line ranging from low to high.
plot_day_summary_oclh(ax, quotes[, ...]) Plots day summary
plot_day_summary_ohlc(ax, quotes[, ...]) Plots day summary
quotes_historical_yahoo_ochl(ticker, date1, ...) Get historical data for ticker between date1 and date2.
quotes_historical_yahoo_ohlc(ticker, date1, ...) Get historical data for ticker between date1 and date2.
urlopen(url[, data, timeout, cafile, ...])
volume_overlay(ax, opens, closes, volumes[, ...]) Add a volume overlay to the current axes.
volume_overlay2(ax, closes, volumes[, ...]) Add a volume overlay to the current axes.
volume_overlay3(ax, quotes[, colorup, ...]) Add a volume overlay to the current axes.

Classes

Affine2D([matrix]) A mutable 2D affine transformation.
Line2D(xdata, ydata[, linewidth, linestyle, ...]) A line - the line can have both a solid linestyle connecting all the vertices, and a marker at each vertex.
LineCollection(segments[, linewidths, ...]) All parameters must be sequences or scalars; if scalars, they will be converted to sequences.
PolyCollection(verts[, sizes, closed])
Rectangle(xy, width, height[, angle]) Draw a rectangle with lower left at xy = (x, y) with specified width and height.
xrange xrange(start, stop[, step]) -> xrange object
zip alias of izip