More NaN testing.
Added basic histogram tests.