Merge pull request #1 from lendle/master

Allow regimens to be specified using a 'rule' function that is applied to each row of 'data' instead of a binary array.