Parameterization and minor cleanup
Merge pull request #1892 from tambry/Parameterize

Parameterize things