Scipen
Some code cleanup, fixed #27, fixed #22