This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import expyriment | |
expyriment.control.run_test_suite() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import expyriment | |
for k,v in expyriment.get_system_info().iteritems(): | |
print k + ":\t" + str(v) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" | |
Demonstration of wait callback functions in Expyriment | |
""" | |
from expyriment import control, design, misc, io, stimuli | |
control.defaults.quit_key = None # switch off quitting key |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""written by O. Lindemann""" | |
import numpy as np | |
np.random.seed() | |
def get_transition_matched_sequence(conditions, n_transition_repetitions): | |
""" returns of sequences of conditions, were each transistion is balanced | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
""" | |
Attentional Blink experiment | |
Find the two numbers in the stream. | |
Enter "999" to quit experiment. | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pygame | |
from expyriment.stimuli import Canvas | |
class PGSurface(Canvas): | |
def get_surface_copy(self): | |
return self._get_surface().copy() | |
def set_surface(self, surface): | |
"""surface or pixel_map""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pygame | |
from expyriment.stimuli import Canvas | |
from expyriment.stimuli._visual import Visual | |
def inherit_docs(cls): | |
for name, func in vars(cls).items(): | |
if not func.__doc__: | |
for parent in cls.__bases__: | |
parfunc = getattr(parent, name) | |
if parfunc and getattr(parfunc, '__doc__', None): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Drag and drop | |
Example how to track mouse trajectories under Expyriment by Florian Krause | |
""" | |
from expyriment import control, stimuli | |
control.set_develop_mode(True) | |
exp = control.initialize() | |
exp.mouse.show_cursor() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os as _os | |
def picture_dict(suffix, subfolder="", preload=False): | |
"""Returns a dictionary of Expyriment pictures from files in a subfolder | |
Returns | |
------- | |
picture_dict : dictionary | |
key: filename (with suffix) | |
value: Expyriment stimulus |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" | |
Operation Signs Spatial Associations. | |
Use arrow keys | |
""" |