Pigs are much more like humans than you think.

As it turns out, the animal, known to be very intelligent, can be classified as glass half-full or half-empty creatures; optimism and pessimism are not exclusive to humans after all. Furthermore, these traits largely depend on their personalities and moods, according to a report from Phys.org.

In a study published in Biology Letters, scientists from the University of Lincoln discovered these subtleties in individual pig personalities.

"This finding demonstrates that humans are not unique in combining longer-term personality biases with shorter-term mood biases in judging stimuli," the researchers wrote on their paper.

To reach a conclusion, the scientists observed a total of 36 pigs. First, they tested whether pigs have a proactive or reactive personality, the former being active and less flexible (associated with extroversion in humans) and the latter being passive and more flexible (associated with neuroticism).

Cognitive bias was also tested by training the pigs to recognize a good outcome in one end of the room (chocolates) and a bad outcome in another one (coffee beans), which have all been coated in sugar to avoid the animals sniffing them out from afar. After a while, the scientists began mixing up the locations of the bowls, putting them in more ambiguous places.

The environment was also controlled as the team placed the subjects in economy or deluxe accommodations, the latter being more expansive with deep, comfy straw.

Proactive pigs were likely to check the middle bowl, despite the certainty of the "good outcome." Their accommodations also did not matter, keeping their optimism intact even with economy lodging.

Meanwhile, the reactive pigs became more optimistic in finding a chocolate reward in the middle bowl if they were accommodated in the deluxe lodgings. When they're in a slightly less optimal pen, their pessimism also increases. Thus, reactive animals are more flexible, with moods more easily affected by their environment.

"These results suggest that judgment in non-human animals is similar to humans, incorporating aspects of stable personality traits and more transient mood states," the authors explained.