summaryrefslogtreecommitdiff
path: root/code/glue/plot_spike_time_hist
blob: ad4530525b31d3c631ff41c2da86cee9b200b995 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/bash

if [ -f "spikes.out" ]; then
    cat spikes.out | cut -d, -f1 > spikes.out.timing

    echo "x = load('spikes.out.timing');
          y = hist(x, ceil(max(x)/10));
          y'" \
    | octave -q \
    | tr -dc "0123456789.\n" \
    | grep -v "^$" \
    > spikes.out.binned-timing

    echo "set title 'population frequency $PWD'
          set terminal postscript
	  set output 'spikes.out.binned-timing.ps'
	  plot 'spikes.out.binned-timing' using 1 with lines" \
    | gnuplot
fi
contact: Jan Huwald // Impressum