Skip to content

Commit

Permalink
GH-771 remove sham_change column from trials
Browse files Browse the repository at this point in the history
  • Loading branch information
nicain committed Jun 25, 2019
1 parent 6a3265e commit 06995c7
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions allensdk/brain_observatory/behavior/trials_processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,16 +182,13 @@ def get_trials(data, licks_df, rewards_df, rebase):
reward_times = rebased_reward_times[np.where(np.logical_and(rebased_reward_times >= start_time, rebased_reward_times <= stop_time))]
trial_data['reward_times'].append(reward_times)

sham_change = True if ('sham_change', '') in event_dict else False
trial_data['sham_change'].append(sham_change)

stimulus_change = True if ('stimulus_changed', '') in event_dict else False
trial_data['stimulus_change'].append(stimulus_change)

change_time = event_dict.get(('stimulus_changed', '')) or event_dict.get(('sham_change', '')) if stimulus_change or sham_change else float('nan')
change_time = event_dict.get(('stimulus_changed', '')) or event_dict.get(('sham_change', '')) if stimulus_change or catch else float('nan')
trial_data['change_time'].append(change_time)

if not (sham_change or stimulus_change):
if not (catch or stimulus_change):
response_latency = None
else:
if hit or false_alarm:
Expand Down

0 comments on commit 06995c7

Please sign in to comment.