clear meanSpec temp
x2 = 0.02:0.001:0.5;
for i=1:15
    for j = 1:12
        if (sum(isnan(WSStruct(i).meanSpectrum(j,:)) == 0))
            interpSpec(i,j,:) = interp1(WSStruct(i).freqVector, WSStruct(i).meanSpectrum(j,:),x2);
        end
    end
end

%Matlab mean function doesn't deal with NaN so this section does
for i = 1:12
    for j=1:length(interpSpec(1,1,:))
        temp = interpSpec(1:15,i,j);
        nanRows = find( isnan(temp) == 1 );
        temp(nanRows) = [];
        meanSpec(i,j) = mean(temp);
        clear temp 
    end
end
waterfall(x2,1:12,meanSpec)