Thank you Gleb. I’m glad it was helpful. There are no built-in stimulation protocols per se. You define such things explicitly in your model. In my demo, I used a constant stimulus (Je). Other common stimulation protocls are a step function and a square pulse. I like to use a step-function at t=0 because its very easy to code.
dY = F(t,Y,J)
% set the stimulus to J=0 for t<0
if t < 0
% your equations here
dY = ..... + J
You can then start your simulation at, say t=-100, to observe the stimulus onset at t=0. It is very easy to adjust the time domain in the graphical interface.
You do a similar thing with pulse stimuli. You just need to add another parameter for the stimulus duration.
if t < 0 || t > dur
As for event-related potentials in the EEG. Your model would need to describe the equations for the EEG. However you do that would be specific to your study. To get started, you could look at the BOLD Haemodynamic Response Function (BOLDHRF) that ships with the toolbox. That’s more for fMRI but it might give you some clues on how to proceed.