## Read in the "measured" radiances hdr <- scan(file="/home/hcp/wrk/invth_pract/newrads.dat",nlines=1) nprofs.rad<-hdr[1] nfreq.rad<-hdr[2] ## nprofs.rad is the number of sets of radiances and hence the ## number of profiles you are to try to estimate. ## nfreq.rad should be the number of channels and will be the same as ## in the other files. y.meas <- scan(file="/home/hcp/wrk/invth_pract/newrads.dat", nlines=nfreq.rad,skip=1) dim(y.meas) <- c(nprofs.rad,nfreq.rad) ## y.meas is now an array containing the radiances for which you need to ## estimate the profiles.