MAINT: Updated libraries

iso8601, pytz, numpy, python-dateutil, six, Cython, requests,

nose-parameterized, nose-ignore-docstring, scipy, matplotlib,
patsy

Note that patsy must install before statsmodels.
MAINT: Use six for Python 3 compatible names and behavior.

Use the six module to import functions and types that are
consistent between Python 2 and 3, so that one code base can
support both versions.

- Use integer types instead of int and long.
- Use string_types instead of basestring.
- Account for iteritems, itervalues, iterkeys.
- Use six.moves for filter and zip, reduce
- Use compatible bytes for md5 hasher.
- xrange and range
MAINT: Use explicit relative pathing for Python 3 compatibility.

Python 3 requires submodules to have more explicit pathing, so use
the dot syntax to declare submodules which are in the same directory
as another module.
MAINT: Make answer key reading compatible with Python 3.

Ensure reading of bytes and checking against byte type, when
parsing the Excel spreadsheet which contains the answers.
MAINT: Explicitly convert map to list when converting answer key values.

For compatibility with iterator version of map in Python 3.

Also always use iterator version of map,
so that code path is exercised in Python 2.
MAINT: Remove type checking which trip up Python 3 compatibility.

Instead of porting these cases of type checking, remove them instead.
Slightly more Python-ic to be more generous in what is allowed, and
the conversion to make these compatible with Python 3 are more trouble
than they are worth.
MAINT: Support both Python 2 and 3 next interfaces.

Python 3 uses the `__next__` method instead of `next`,
and uses the syntax of `next(foo)` accordingly.

Add `__next__` and `next` side-by-side so both Python 2 and 3 have
a method that can be used during iteration.
MAINT: Make walk usage in example tests compatible with Python 3

The rename of walk is not provided by six, so check the import error
via an exception.

Also, callback behavior slightly changes between the two versions,
so instead iterate over the walked files and call what was formerly
a callback, directly as a function.
MAINT: Make exception handling tests compatible between Python 2 and 3

Python 3 removes the `.message` attribute, so use `str` instead.

Also, the divide by zero message has changed slightly between versions,
so just check for the exception type, instead of also checking the message.
MAINT: Adjust for comparison changes in Python 3.

Use date sorted sources instead, instead of sorting with second
argument of Event, etc. since the `heapq.merge` behavior is using
the second part of the tuple, thus requiring a richer set of comparison
methods, which would only be used in the test context.

Use `date_sorted_sources` instead, so that sorting is done on algo time
and source id.
MAINT: Use Python 3 compatible metaclass.

Use six's with_metaclass to have objects that use metaclasses, in
both Python 2 and 3.

Otherwise, in Python 3 the objects were being treated as if they
did not have a metaclass, when the Python 2 syntax is used, leading
to errors because of missing attributes, etc.
MAINT: Read text in Python 3 instead of bytes when fetching public data.

Account for byte/string compatibility when consuming response from
requests module.
MAINT: Use pandas for data cache file I/O

The compatibility between the two versions was made easier by
letting pandas handle the heavy lifting, so pass filenames to the
pandas serialization methods, instead of dealing doing the file
handling and reading/writing within the data module.
BLD: Use Python 3 on Travis.

To help prevent regressions when a changes are developed using
Python 2.7, also test Python 3 during continuous integration.
Merge Python 3 compatibility branch.

This branch should make it so that the code base can be run
using both Python 2.7 and Python 3.3
STY: Remove unused import.

Remove unused heapq from test perf tracking.

Mea culpa.
BUG: Fix check for cached public data for Python 2.7

Python 2 and 3 throw different exception types when a file does
not exist.

Catch both exception types to trigger the download, so that the
loader works under both Python versions.
BUG: Make write of binary file compatible with Python 3.

Open the destination file with the byte flag to avoid error in
Python 3 with mismatch of str and byte.
REL: Release v0.6.0

Highlights

- Reworked risk metrics, including verification against Excel spreadsheet
- Additional order methods
- Conversion of many data structures to use pandas
- Change to behavior of stop and limit orders (@pcawthron)
- Use pandas timezone handling throughout instead of Delorean
- New commission model (@stanh)
- Adds beginning of support for Toronto stock exchange. (@dstephens)
- Python 3 compatibility.
  Unit tests now pass when run with Python 3.3, and Python 3 should
  now be considered officially supported.
  If anything does not work under Python 3, please file as a bug.
REL: Add Python 3 to PyPI classifiers.