Now accepts functions. Close #1
Release 0.2.4