The raw output of the spectra code is: Column 1 Column 2 Column 3 Column 4 wavenumber (cm^-1) Ones Relative Absorption 1 - column 3 10,000/column 1 = microns (col 3+4) This is the column you want For the rest of this document, column 1 will be in the variable "wave" and column 3 will be "fraction" You can use a smearing routine to downsample the highresolution spectra For direct detection spectra: For IR spectra Make a variable for the surface temperature of the Planet, Tsurf Make sure you do proper unit conversions. ie) for W/m^2/um watts=1.e-7 ;ergs to watts scale=1.e-4 ; conversion for 1/cm to 1/um scale2=1.e4 ; conversion for 1/cm^2 to 1/m^2 so you might want to multiply your column 3 by something like:Unit_conversion= watts*scale*scale2*pi for W/m^2/um For the IR specta, multiply by the blackbody of the surface temperature of your radiating planet Ultimately what you will plot for the top of the atmosphere emergent IR flux will be something like: Unit_conversion*Column_3*2*h*c^2*wave_number(column1)^5/(exp(h*c*wave_number/k/Tsurf)-1) For the VIS spectra You have to consider the reflected stellar spectrum and the wavelength dependent albedo of the surface. Rayleigh scattering is not included in the spectra. You have to use an analytical approximation and add that in directly. So for the flux at the top of the atmopshere you will have something like: column_3*wavelength_dependent_albedo_surf*Rayleigh_scattering*Unit_conversion*star_flux