Ocean Color Forum - Not logged in
My question is easy, exist some possibility to apply l2 flags to a image display using the command mode of SeaDAS?
Now I have 2 new questions.
1) How I can change dimensions of l2_flags product to be equal to dimensions of map projection and apply the mask in the projection?
2) How do should be this action in command mode? I mean to apply the mask of l2_flags product to the projection obtain in the previous step.
This is my case:
f = findfile('*L2_LAC_OC*')
n = n_elements( f )
lat = 28
lon = -16
tierra = 255
escala = 3500000
paleta_chl = '/Users/Tony/seadas6.3/config/color_luts/standard/02-standard_chl.lut'
paleta_calcita = '/Users/Tony/seadas6.3/config/color_luts/standard/10-standard_calcite.lut'
load, f[n-1], FTYPE='MODIS', PROD_NAME=['chlor_a',¿'l2_flags'?] & $
loadpal, paleta_chl, /file_idl
loadgp, color=5, red=tierra, green=tierra, blue=tierra
display, BAND_NO=2, FBUF=1, smax=65.00, smin=0.01, STYPE='LOG'; LIN o LOG
landmask, FBUF=1, COLOR=5; overlay landmask
cbar, FBUF=1, orient='v', fonttype=-1, charsize=2
out, 'chlo.tiff', FTYPE='tiff', FBUF=1, /CBAR, bk_cbar=0 ; black background
out, 'chlo.png' , FTYPE='png' , FBUF=1, /CBAR, bk_cbar=0 ; black background
out, 'clo.hdf' , fbuf=1, /DATA, ftype='hdf', dfmt=1, win=1
The l2_flags are meaningless if you map them. They have to be applied to the data prior to mapping.
You would have to use the flags to create a mask and then create a new band with the masked data
set to a missing value, then map the new band.
Or you could use l2bin, which will do this for you. Then smigen to create a map of the binned data.
Hello again, Sean
Sorry to ask again for the same subject, but I haven't clear some things. When I apply the mask to a data display, I can't save the image with the mask applied. How can I save this image without lost the mask applied? Now I work with display mode of seadas and when I have the way to make this, I will try to do it with the command mode.
Moreover, can you explain a little more the last sentence "Or you could use l2bin, which will do this for you. Then smigen to create a map of the binned data"? I say to that all process should be in level_2 and l2bin is related with level_3.
The binner will exclude pixels from binning that are flagged by a set of l2_flags defined in the flaguse parameter.
If you are only interested in creating a mapped image with certain flags masked, l2bin may not be the desired
approach. However, if you intend to use the data - creating spatial/temporal composites, l2bin may suite your
needs better. The forum has pletny of posts explaining mapping and binning...