Pretty good question! It's a good chance for Pokebase to finish up explaining the misunderstood Hidden Power.
Hidden Power is different for each and every Pokemon, not each species. It's all dependent on the IVs of your Ditto (IVs are values given to the stats of a Pokemon from creation or birth. It defines how your stats start and grow), meaning he'd keep the same type of Hidden Power, no matter what he transformed into, since it's based on his own qualities and variables, rather than any other Pokemon's.