disp('AMMA_flux_10');
fclose('all');
clear jazz;
%This program takes data computed by the jas, nar, or kwaj da_red2.m progam and creates an ascii
%file appropriate for reading into a spreadsheet (e.g., lotus, quatropro, etc)
%To use it, you must first run the analysis program, or stick a call to thisin it




npz=length(jdy);
jazz(1,1:npz)=jdy';						%date
jazz(2,1:npz)=ushp_im';						%uship speed
jazz(3,1:npz)=U';							%u true
jazz(4,1:npz)=dir';						%true dir
jazz(5,1:npz)=urel';						%u rel
jazz(6,1:npz)=reldir';					%rel dir
jazz(7,1:npz)=head';						%ship heading
jazz(8,1:npz)=tsg';					%Ts ship water temperature 5 m depth
jazz(9,1:npz)=ta';						%T
jazz(10,1:npz)=qse';						%%sea surface specific humidity, g/kg (from snake)
jazz(11,1:npz)=qa';						%qa	
jazz(12,1:npz)=hsc';						%hs covariance
%jazz(13,1:npz)=hsib';					%hs ID
%jazz(14,1:npz)=hsbb';					%hs bulk						
%jazz(15,1:npz)=hlc_bl';					%hl covariance
%jazz(16,1:npz)=hlib_lic';					%hl ID
%jazz(17,1:npz)=hlbb';					%hl bulk
jazz(13,1:npz)=-(rhoair.*wu)';		%stress streamwise covariance
jazz(14,1:npz)=-(rhoair.*wv)';		%   "     xstream
%jazz(20,1:npz)=(rhoair.*usib.^2)';	%stress ID
%jazz(21,1:npz)=taubb';					%stress bulk
jazz(15,1:npz)=rs';						%solar flux
jazz(16,1:npz)=rl';						%IR flux
jazz(17,1:npz)=org';						%ORG rain rate
%jazz(25,1:npz)=jplume';					%ship plume contam index
%jazz(26,1:npz)=min(999,sigoph');		%sigoph of good data
jazz(18,1:npz)=tiltx';					%tilt of good data
%jazz(27,1:npz)=jmanuv';					%maneuver index
jazz(19,1:npz)=ct';						%ct
jazz(20,1:npz)=cql';						%cq licor
jazz(21,1:npz)=cu';						%cu
jazz(22,1:npz)=cw';						%cw
%jazz(32,1:npz)=HRF';						%Rain heat flux
%jazz(33,1:npz)=hl_webb';					%Hl webb flux
jazz(23,1:npz)=Lat';						%lat
jazz(24,1:npz)=Lon';						%lon
jazz(25,1:npz)=zu_etl';					%zu
jazz(26,1:npz)=zt_etl';					%zt
jazz(27,1:npz)=zq_etl';					%zq
jazz(28,1:npz)=ushp_im'; 				%uship  scs
jazz(29,1:npz)=U_scs';					%u true	scs
jazz(30,1:npz)=dir_scs';				%true dir scs
jazz(31,1:npz)=x(:,101)';				%ship course scs 
jazz(32,1:npz)=tsg';						%Ts scs
jazz(33,1:npz)=ta_im';					%T scs
jazz(34,1:npz)=qs_tsg';					%qs scs
jazz(35,1:npz)=qa_im';					%qa scs	 
jazz(36,1:npz)=rs_im';                  %solar flux  IMET
jazz(37,1:npz)=rl_im';			    %IR flux IMET
%jazz(50,1:npz)=hlc_lic';		    %hl covariance Licor
jazz(38,1:npz)=wco2_lic';           %w’c’
%jazz(52,1:npz)=hlc_oph';             %Cov. Latent Heat Flux from Ophir
jazz(39,1:npz)=q_lic';               %Specific Humidity from Licor (g/kg)
%jazz(54,1:npz)=q_oph';               %Specific Humidity from Ophir (g/kg)
%jazz(55,1:npz)=ophm';                %Median of Ophir Clear Channel (counts/s)
%jazz(56,1:npz)=sigoph';              %Stv of Ophir Clear Channel (counts/s)
jazz(40,1:npz)=sgq_lic';             %Stv of Specific Humidity from Licor (g/kg)
%jazz(58,1:npz)=sgq_oph';             %Stv of Specific Humidity from Ophir (g/kg)
%jazz(59,1:npz)=hlib_lic';					%hl ID
jazz(41,1:npz)=ww;                    %variance of w' ((m/s)^2)
jazz(42,1:npz)=wt_son;                % sonic w'T' covariance before the hunidity contribution
jazz(43,1:npz)=lagtime;               % lagtime between w and O3 calculated by crosscovriance, 10 min lagtime
jazz(44,1:npz)=O3w_o;              % w'O3' calculated with crosscovariance, 10 min lagtime, no webb correction
jazz(45,1:npz)=O3mean_o;           % mean O3 concentration cross (ppb)
jazz(46,1:npz)=O3dev_o;            % stdev ozone cross (ppb)
jazz(47,1:npz)=O3w;                % O3'w' with constant lagtime of 5.1 s, and function cov, no webb correction
jazz(48,1:npz)=O3mean;              % mean O3 concentration constant lagtime (ppb)
jazz(49,1:npz)=O3dev;              % stdev ozone constant lagtime (ppb)
jazz(50,1:npz)=-O3w_o./O3mean_o*100;% deposition velocity 10 min lagtime (cm/s)
jazz(51,1:npz)=-O3w./O3mean*100;    % deposition velocity 5.1s lagtime (cm/s)
%jazz(67,1:npz)=O3w_oc;              % w'O3' calculated with crosscovariance, 10 min lagtime, webb correction
%jazz(68,1:npz)=O3w_hc;              % w'O3' calculated with crosscovariance, flux at hourly mean lagtime, webb correction
%jazz(69,1:npz)=O3w_dc;              % w'O3' calculated with crosscovariance, flux at dayly mean lagtime, webb correction
%jazz(70,1:npz)=O3wc;                 % O3'w' with constant lagtime of 5.1 s, and function cov, webb correction
%jazz(71,1:npz)=-O3w_oc./O3mean_o*100;% deposition velocity 10 min lagtime (cm/s)
%jazz(72,1:npz)=-O3w_hc./O3mean_o*100;% deposition velocity hourly lagtime (cm/s)
%jazz(73,1:npz)=-O3w_dc./O3mean_o*100;% deposition velocity dayly lagtime (cm/s)
%jazz(74,1:npz)=-O3wc./O3mean*100;     % deposition velocity 5.1s lagtime (cm/s)
jazz(52,1:npz)=slowO3;
jazz(53,1:npz)=slowO3std;
jazz(54,1:npz)=rhoair;                      %density of dry air
jazz(55,1:npz)=tsnk;
jazz(56,1:npz)=ustr;
jazz(57,1:npz)=sp2;                         %std motion correction
jazz(58,1:npz)=sig_uim;                     %std ship speed
jazz(59,1:npz)=sig_h;                       %std heading
jazz(60,1:npz)=hsc;                         % solar heat fluxes
jazz(61,1:npz)=hsc_son;
jazz(62,1:npz)=hlc_lic;


jazz=jazz';

save(['C:\Data\AMMA\AMMA_SEP08\AMMA_flux_10uf_SEP.txt'],'jazz','-ascii');
	
