function ep1argoslook(NumOfDays) % EP1ARGOSLOOK - Load argos data file and plot the number of times each of the % buffers from the oasis date were transmitted over the previous day. % Peter Strutton % 22 Dec 1998; Brian Schlining % Prompt for input if no input arguments are specified if ~nargin NumOfDays = str2num(input('How many days of data would you like to view? ','s')); end % Set the path to the data file depending on what type of machine this function is run from FileName = 'argos'; switch computer case 'PCWIN' % Assumes the pwd is /oasis/epqac/brian/ FileLoc = ['//tsunami.shore.mbari.org/oasis/eqpac/ep1/' FileName]; otherwise % Assigns an absolute path FileLoc = ['/hosts/tsunami/oasis/eqpac/ep1/' FileName]; end loc = '0 155W'; %X = load(FileLoc); % Load the file load(FileLoc); %X = argos; %[rX cX] = size(X); % Get it's size %NumBuffers = cX - 2; % Count the number of buffers (Columns) %D = dy2date(X(:,1)+1900); % Convert decimal year to serial date numbers X = readeqpac(FileLoc,NumOfDays); [rX cX] = size(X); % Get it's size NumBuffers = cX - 2; % Count the number of buffers (Columns) % Create a new figure figH = figure; set(figH,'Name',['Hits from ARGOS buffers 0 to ' num2str(NumBuffers - 1)]) %plot(D((rX - NumOfDays):rX),X((rX - NumOfDays):rX,3:cX)) plot(X(:,1),X(:,[3:end])); xlabel('Date') ylabel('# Hits') %hold on if NumOfDays < 50 dtick = 6; else dtick = 3; end datetick('x',dtick) title(['Hits from ARGOS buffers 0 to ' num2str(NumBuffers - 1) ' at ' loc]) % Create the legend lS = repmat('buf',[NumBuffers 1]); lS(:,4) = num2str([0:(NumBuffers - 1)]'); legend(lS,0); setfontsize(7);