Skip to main content

A PsychoPy wrapper to create moving visual stimuli without loops.

Project description

PyPI version PyPI pyversions Documentation Status Code style: black Imports: isort Checked with mypy

StimPy

StimPy is a thin PsychoPy wrapper to simplify the creation of visual stimuli.

Installation

Use the package manager pip to install StimPy.

pip install stimpy

Usage

import stimpy as sp

circle = sp.visual.Circle(
    size=(2, 2), fillColor=(1, 1, 1),
    pos=sp.Animate([(-40, -20), (-40, 20), (40, 20), (40, -20)], [1, 1, 1, 1])
)

scene = sp.Scene(color=(-1, -1, -1), units="deg")
scene.add(circle, begin=0, dur=4)

win = sp.Window(distance=13, width=26)
trial = sp.Trial(scene, win=win)
trial.start()

trial.save_movie("example.mp4", fps=60)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stimpy-0.3.0.tar.gz (10.0 kB view hashes)

Uploaded Source

Built Distribution

stimpy-0.3.0-py3-none-any.whl (12.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page