A Simple Cognitive Study with Code

In the world of cognitive science, one thing is certain: we know very little about how our brains work. But through conducting studies and observing various phenomena, we now have a much better understanding of the intricate inner-workings of our minds.

So, today, in the spirit of cognitive exploration, we are going to try and conduct our very own study. To do this, we will use the gold-standard of scientific inquiry, the “Scientific Method.” The Scientific Method is exactly what it sounds like, a methodical and systematic approach to scientific inquiries. One must ask a question, do some background research, and then construct a hypothesis (an answer to our question). Then one must test our hypothesis and make sure our procedure (the steps we take) removes all outside variables that would affect our data. Finally, we analyze data and draw conclusions, and see how our results match-up with our predictions.

For those of you who like visuals, here is a visual representation of scientific method: 


So now how are we going to apply those steps? But first, some background. Is there a relationship between how our brains work and how computers work? Some theorists argue that there is. More specifically, the computational theory of mind views our minds as an information processing system. The same way a computer uses basic logic gates to solve complex problems, our brain uses complex neural networks to solve problems.

Take the following example. Have you ever noticed how good you are at finding your parents in a crowd of people? If we were to apply our ability to recognize faces to computational theory, any face our eyes see can be understood as the ‘input’. Our brain takes this input, sorts through our database of previously memorized face templates, and processes until out input is matched to the correct template. Could this be how our brain works?

Maybe – but our ability to distinguish one face from another seems to be much more complex than this, as we not only have to remember what the face looks like from the front, but also from all different angles as well. This caused a lot of scientists to ask whether or not faces are special. Robert Yin, was one of the scientists that first explored this problem in the 60s. He noticed that we are much slower at recognizing faces once they’ve been turned upside down, but that we could recognize inverted objects such as household appliances, just as well. This effect, was coined as the face inversion effect.

Ok so back to the scientific method. We are going to recreate the face inversion effect, but this time our question is a little different: Does the face-inversion effect apply to animals? To test this we will first show users six faces face-down and see how many they recognize. Then we will show the same six-faces face-up and record how many are recognized. We will repeat this process with animal pictures. Each time, the users will have 7 seconds to recognize the pictures. We hypothesize that in both the animal and human cases it is harder to recognize upside down photos, but this effect will be more pronounced with the humans.

To run our tests we use the power of computer science! More specifically, we can code these tests and have them print the results at the end. We created versions in Scratch, JavaBlocks, and Processing. Here are some screenshots of the code, and also a Processing script. If you’d like to see the Scratch version click here!





With this code template you can now design your own experiment! You can change the image links in the code and even change affects like the duration and add color-filters on images. Some things that interest us would be looking at the inversion effect on animated faces from cartoons and movies. What about animated objects? Is it harder to recognize objects and people in black and white? Comment below and let us know your thoughts and what you would want to test!

Leave a Reply

Your email address will not be published. Required fields are marked *