Clamp method is wrong

- the order of the parameters "max" and "min" is inverted (based on how they are used)
- the method is wrong. it doensnt set the right bounds
Merge pull request #15 from carlonzo/master.fixClamp

Clamp method is wrong