function output_array = m1_ecofl_calibrate(input_array)
% m1_ecofl_calibrate - Provide calibrated output data for the Fluorometer.
%
% Use as: output_array = m1_ecofl_calibrate(input_array)
%
% Inputs: input_array = Array of raw counts data.
%
% Output: output_array = an array of raw and calibrated data elements.
%
% Example:
%   output_array = m1_ecofl_calibrate(input_array)
%output_array =
%
% lalala - needs some work here
% Where Col(1)=datenum,  Col(2)=OASIS time, Col(3)=reference, Col(4)=signal, and Col(5)=thermistor.

% MC Harlan
% 21 Nov 2003

% take column 4, do some calculations, and produce column 6...

SCALE_FACTOR = 0.0078; % from calibration sheet
[rows,cols] = size(input_array); % returns the size of matrix X in separate variables.
fprintf(1,'rows=%d  cols=%d\n', rows, cols);
output_array = input_array;

for row = 1:rows
   output_array(row, cols+1) = (input_array(row,4) - 76.0) * SCALE_FACTOR;
end

return;