Different animals choose different habitats because of the conditions - light, moisture and warmth. Animals' needs can be investigated in different ways.
We can search for animals and record where they are found.
We can also carry out an experiment to show which conditions animals prefer, by making 'mini' habitats and very carefully collecting animals and observing their behaviour.
Scientists will record their observations, often in a table. Using this information, we can then see if there are any patterns in our findings.
When studying the number (population) of animals in a particular environment, scientists will often sample an area. It would be impossible to count all the ants in our back garden for example! We might look at a small area of our garden instead and count the number of ants in that area only. We would then use that figure to estimate the number of ants for the rest of the garden.
Scientists handle animals (and their habitats) very carefully and, after their investigation, they return them to where they were found as quickly and as safely as possible.