%plot LFP files
%requires eeglab
clear; close all; clc;

addpath(genpath('/Users/dino/DATA/matlab/eeglab/'));

drIN = 'MAT_EEG/';
files = dir([drIN '*.mat']);

%file index to plot
fI = 1;

fnEEG = files(fI).name;

load([drIN fnEEG])

%make color array
cols = {'k';'r';'k';'r';'k';'r';'k';'r'};
colors = [];
for i = 1:8
    for j = 1:4
        colors = cat(1,colors,{cols{i}});
    end
end

%plot data
eegplot(eegData, 'srate', eegFS, 'winlength', 3, 'spacing', 0.001, 'color',colors );

