1 subroutine da_read_biascoef(string,nchan,nscan,nband,npred,global, &
2 scanbias,scanbias_b,coef,coef0, vstd_dep)
4 integer, intent(in) :: nchan,nscan,nband,npred
5 logical, intent(in) :: global
6 character(len=20), intent(in) :: string
7 real, intent(inout) :: scanbias(nchan,nscan)
8 real, intent(inout) :: scanbias_b(nchan,nscan,nband)
9 real, intent(inout) :: coef(nchan,npred),coef0(nchan)
10 real, intent(inout) :: vstd_dep(nchan)
12 integer :: iunit,j,i, ii,jj, iost
13 integer :: nobs(nchan)
14 real :: vmean_abs(nchan)
15 real :: vstd_abs(nchan)
16 real :: vmean_dep(nchan)
18 character(len=80) :: filename
20 call da_trace_entry("da_read_biascoef")
22 call da_get_unit(iunit)
23 filename='biascorr/'//trim(adjustl(string))//'.bcor'
24 open(unit=iunit,file=filename, form='formatted',iostat = iost, status='old')
26 message(1)="Cannot open radiance biascorr file "//adjustl(filename)
27 call da_error(__FILE__,__LINE__,message(1:1))
30 ! read (iunit,'(4i6)') nchan,nscan,nband,npred
33 read (iunit,'(i5,i10,4F8.2)') ii,nobs(i),vmean_abs(i),vstd_abs(i), vmean_dep(i),vstd_dep(i)
37 read (iunit,'(i5,5F12.5)') ii,(coef(i,j),j=1,npred),coef0(i)
42 if (global) then ! global coefs not available now, use regional one
44 read(iunit,'(i5,90F7.2)') jj, scanbias(j,1:nscan)
48 read(iunit,'(i5,90F7.2)') jj, scanbias(j,1:nscan)
53 call da_free_unit(iunit)
55 call da_trace_exit("da_read_biascoef")
57 end subroutine da_read_biascoef