ArticleslgStudy

computer science

PsychoPy

PsychoPy is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand PsychoPy rather than just read about it. In short: PsychoPy is an open source software package written in the Python programming language primarily for use in neuroscience and experimental psychology research. Developed initially as a Python library and then as an application with a graphical interface, it now also supports JavaScript outputs to run studies online and on mobile devices.

PsychoPy — main illustration
PsychoPy — illustration

Key takeaways

  • PsychoPy belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect PsychoPy to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of PsychoPy from memory before moving on to harder problems.

Reference excerpt

PsychoPy is an open source software package written in the Python programming language primarily for use in neuroscience and experimental psychology research. Developed initially as a Python library and then as an application with a graphical interface, it now also supports JavaScript outputs to run studies online and on mobile devices. Unlike most packages, it provides users with a choice of interface - they can generate experiments by writing Python scripts, use a graphical interface that will generate a script for them, or combine both methods. Its platform independence is achieved through use of the wxPython widget library for the application and OpenGL for graphics calls. It is also capable of generating and delivering auditory stimuli. The project was initially supported only by volunteer code and forum contributions alongside grants from The Royal Society, The University of Nottingham, Wellcome Trust, and BBSRC project. A 2018 grant from the Wellcome Trust allowed for hiring of a full-time staff. According to its usage statistics page, Psychopy was launched on more than 20,000 different computers in November, 2018, and has gained relative usage by month every year since its initial release in 2003.

History and versions PsychoPy is continually updated with 5-10 releases each year, containing new features and bug fixes. Here are some major releases in the history of PsychoPy:

PsychoPy : library and code editor 2002: PsychoPy was originally written by Peirce as a proof of concept - that a high-level scripting language could generate experimental stimuli in real time (existing solutions, such as Psychtoolbox, had to pre-generate movies or use CLUT animation techniques). The project was initially registered on sourceforge.net under the name "psychpy" on 14 March 2002. 2003-2005: this was extended to be able to generate experiments in the author's lab at Nottingham University and made available as an open source project on the internet. At this time PsychoPy was a library (Python package) that could be imported by Python scripts. Installing was complex because of the dependencies. 2006: An editor was added, so that users could use PsychoPy as an 'application' rather than a library April 2009: Version 1.0 released, including all main features of the library PsychoPy2 : addition of the graphical Builder interface. Note that, although this phase of development gave the application the name PsychoPy2, version 2.0 itself was never released. September 2009: Version 1.50 released, including a preview of new GUI interface. This new interface, the Builder view, allowed users to generate a very wide range of experiments without a knowledge of programming. April 2011: Version 1.64 Used for both research and undergraduate teaching at various universities. Over 1500 users per month worldwide. June 2013: Version 1.77 released, including ioHub for faster (asynchronous) polling of hardware. September 2014: Version 1.81 released, including the ability to specify PsychoPy version in the experiment. PsychoPy will then load this version during run-time, regardless of the version installed - including future versions. July 2016: User support forum migrated to hosted service by Discourse.com (from googlegroups) March 2018: Version 1.90 released, first version with Python 3 support. PsychoPy3 : running studies online Jan 2018: Wellcome Trust Technology Development Grant awarded to fund development of online experiment support August 2018: Official launch of PsychoPy3 (several beta releases followed) and pavlovia.org website to support hosting and sharing of studies Jan 2019: Support for PC connected Oculus VR headsets.

Key people A large number of people have contributed to the project over the years, in terms of code, but also by supporting users on the community forum. A few of the major contributors are listed below:

Jonathan Peirce Jeremy Gray Michael MacAskill Sol Simpson Richard Höchenberger Alain Pitiot David Bridges Jonas Lindeløv Erik Kastman Hiroyuki Sogo Matthew Cutone Damien Mannion Yaroslav Halchenko

References

External links Official website PsychoPy Github Project Page

Illustrations

PsychoPy illustration

Worked examples

Example 1 — a first encounter with PsychoPy

Start with the simplest possible case. Write down what PsychoPy claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to PsychoPy before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about PsychoPy ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of PsychoPy

In research
PsychoPy appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses PsychoPy in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
PsychoPy is common in secondary-school and first-year university syllabi. It links to neighbouring topics 2003 software, Behavioral experimentation software, Free software programmed in Python, so understanding it makes those chapters shorter.
In everyday life
Look for PsychoPy outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.

Affiliate

Preply — study more efficiently by working with a personal tutor. 50% off.

How to study PsychoPy in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what PsychoPy means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain PsychoPy out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is PsychoPy in simple terms?

PsychoPy is an open source software package written in the Python programming language primarily for use in neuroscience and experimental psychology research. Developed initially as a Python library and then as an application with a graphical interface, it now also supports JavaScript outputs to ru…

Why does PsychoPy matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study PsychoPy?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on PsychoPy.

Tags

  • 2003 software
  • Behavioral experimentation software
  • Free software programmed in Python
  • Neurotechnology
  • Psychology experiments
  • Python (programming language) scientific libraries
  • Science and technology in Nottinghamshire
  • Software using the GNU General Public License
  • University of Nottingham

Keep exploring