Added canonical option. Close #6.