How was it determined that animals were clean or unclean?

In Old Testament days there were no antibiotics or other types of medication that we use so freely today. So, God's primary purpose in calling some animals unclean and forbidding their consumption, was to keep the people healthy. People were forbidden to eat scaleless fish--crustaceans, shellfish--because those animals were created to clean the ocean of its bacteria. People were also told not to eat pork. This is because pigs do not have sweat glands, so the impurities remain in the fat of pigs.

Today, not only are we not under the Law, which forbade the consumption of those foods and we have built up immunities to the bacteria that would have caused much damage to those people. And when we do get sick from fish, pork, or other ways--we have natural homeopathic, herbal and prescription medicines to help us counteract the occasional ill-effect from some of these foods. Our methods of cleaning and storing such foods, has also gotten much safer.