disp('read_ptu')
fclose('all');
clear all;
jd=input('month, mm','s');
%plotit=input('plot plots? 0=n, 1=y');
%plotit=0;
%prtit=input('append master data file? 0=n, 1=y');
%prtit=1;
%yd=date;
%jif=datevec(yd);
%xx=[jif(1) jif(2) jif(3) 0 0 0];
%jd=num2str(julday(xx)-1);
dy=input('gmt day','s');

hr=input('gmt hr','s');
g=0.0098;%adiabatic lapse rate
eps_w=0.97;%emissivity of water
sig_sb=5.67e-8;%Stefan Boltzmann constant
blk=1;%10-min index 
jax=1;
jam=0;
backchk=0;
   e=['D:\cwf\sondes\990410.001\99' jd dy hr '.ptu'];
	flist=fopen(e,'r');
   if flist>0,   %if the file exists, 
      if backchk==0,
         tzilch=jam;
         backchk=1;
      end;%end if
      for jj=1:44
         dmp=fgetl(flist)
      end;
      
      dmp=fgets(flist);%read header lines and skip blanks
		
      while feof(flist)==0,%go until you run out of 10-min sections
         st1=fgetl(flist);%fscanf(flist,'%g%g%g%g%g%g%g',[7,1])
         %1 2 3 4 5 6 7 
         [nr1,nl1]=size(st1);

      		st2(:,jax)=st1; 
      		jax=jax+1;
		             
      end;%end while
   end;%end flist
