Vector sum macro
Relevant to Figure 2, 3
This ImageJ macro calculates the vector-sum of each pixel in calcium imaging movies with a direction selective (DS) bar stimulus in 8 different directions (0-315 degrees in 45 degree intervals) presented 3 times in a pseudorandomized order (24 bar stimuli in total).
The ordering of the stimuli is unscrambled with the function sortAngles().
The function AvgStim() produces the average response per angle.
Parameters to change:
- HS: set to true if analysing images taken with the Hyperscope (30Hz frame rate), set to false if analysing images with MP2000 (10.67Hz frame rate)
- If using a differing frame rate, change values in line 31-33, 41-43, 49-54
Ouput:
- The macro will output a vector sum pixel map (heat map pictured in Figure 2 and 3).
- The macro will then prompt the user to select ROIs on the vector sum pixel map and add them to the ROI manager
- The macro will output the Amplitude vs Angle Intensity Plots for ROIs and z-profile plots of ROIs