nicer nice plot with data and script

This commit is contained in:
2015-11-16 10:23:55 +01:00
parent 031dfc2dcb
commit 168fdbe902
5 changed files with 33 additions and 20 deletions

View File

@@ -0,0 +1,30 @@
clear all
close all
load('pyramidal_response.mat')
threshold = 20; % mV
figure()
hold on
plot(time, neuronal_data, 'color', [0.2 0.5 0.7], 'linewidth', 1., ...
'displayname', 'membrane voltage')
plot(spikes, ones(size(spikes)) .* threshold, 'ro', 'markersize', 5, ...
'displayname', 'spike times')
line([time(1) time(end)], [threshold threshold], 'linestyle', '--', ...
'linewidth', 0.75, 'color', [0.5 0.5 0.9], 'displayname', 'threshold')
xlabel('time [s]', 'fontname', 'Times', 'fontsize', 11)
ylabel('potential [mV]', 'fontname', 'Times', 'fontsize', 11)
title('ELL pyramidal neuron', 'fontname', 'Times', 'fontsize', 12)
ylim([0 35])
xlim([0 2.25])
box('off')
l = legend(gca,'show');
set(l,'Location','northwest', 'Fontsize', 7, 'LineWidth', 1.);
set(gca, 'XMinorTick','on','yMinorTick','on')
set(gca, 'TickDir','out', 'linewidth', 1.5, 'fontname', 'Times', ...
'fontsize', 11)
set(gcf, 'PaperUnits', 'centimeters', 'PaperSize', [15 7.5]);
set(gcf, 'PaperPosition',[0.0 0.0 15, 7.5], 'Color', 'white')
saveas(gcf, [pwd '/../lecture/images/spike_detection.pdf'], 'pdf')

Binary file not shown.