Skip to content

Realtime analysis of sweeps #2301

Answered by t-b
damianjwilliams asked this question in Q&A
Discussion options

You must be logged in to vote

I'm just guessing what the code is supposed to do but here is a version which plots something:

# define the regions of the trace where to take control and evoked measurements
t_range_control = [20,25]
t_range_evoked = [40,60]
sweepList = 1...10

# select the channel and all of the sweeps
sel = select(channels(AD0), $sweepList, all)

# calculate the absolute values at control and evoked current 
dat_control  = min(data($t_range_control,$sel))
dat_evoked  = min(data($t_range_evoked,$sel))

# calculate the amplitude of the current
sweep_amplitude = $dat_evoked - $dat_control 

# plot the single amplitude value
$sweep_amplitude

I changed the comment character to # from // and also tweaked the

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by t-b
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants