Fixed mistake in rerange function.
moved ploidy and testing functions to internal.
Added tests for greyscale.