QuikSCAT user guide for version 4.0 data?

QuikSCAT user guide for version 4.0 data?

Postby tomk80 » Tue Jul 03, 2018 4:12 pm

Hi I am looking for some guidance on the new flags in the QuikSCAT version 4.0 data set. Is there an updated user guide that can be posted on PO.DAAC somewhere?

If not, I can contact Bryan and Alex to find out and then post here in case others have similar questions.
Posts: 3
Joined: Tue Jul 03, 2018 4:10 pm

Re: QuikSCAT user guide for version 4.0 data?

Postby podaac » Thu Jul 05, 2018 10:09 am

Thank you for your inquiry.

Unfortunately, this user guide is in the final review stage and will likely not be published for another few more weeks.

I will send you a follow-up when document is available or you may want to contact Bryan and Alex directly.

PO.DAAC User Services
Site Admin
Posts: 450
Joined: Mon Oct 22, 2012 4:00 pm

Re: QuikSCAT user guide for version 4.0 data?

Postby tomk80 » Mon Jul 09, 2018 10:53 am

I contacted Bryan Stiles (JPL engineer who works on QuikSCAT processing) and he sent me the following Matlab script for loading the various flags. Note that flags are stored in the variables "flags" and "eflags." The version 4.0 dataset features two new flags:

"flags" bit 6, which marks wind vector cells that are likely corrupted (roughly 3% of total pts)
"eflags" bit 12, which marks wind vector cells that are possibly corrupted (roughly 15% of total pts)

Utilizing the new bit 6 flag will include many wind observations in coastal areas that utilize the new coastal processing, and will also include more wind vector cells in rainy areas, so long as the rain impact is not too large.

By contrast, the new eflags bit 12 takes a more conservative approach in coastal areas and in rainy areas, i.e., flags many more observations.

Here is the script from Dr. Stiles:

function [meaning, data]=read_qs_bit(filename,varname,bit_number);
%% routine for reading QuikSCAT version 4 L2B wind vector product file
%% This documents how to read wind vector quality bits from a QuikSCAT version 4 netcdf file
%% with full checking to make sure you read the right bit
%% without the checking all you need is three lines
%% mask = 2^bit_number;
%% var=ncread(filename,varname);
%% data=bitand(var,mask)/mask;
%%% function l2b=read_qs_bit(filename,varname,bit_number);
%%%% filename = the name of the QuikSCAT version 4 netcdf file
%%%% varname = the short name ('flags' or 'eflags') of the desired wind vector quality flag variable
%%%% bit_number = the number bewten 0 and 15 inclusive or the desired bit from the flag
%%%% meaning = the string from the file metadata that describes the requested bit
%%%% data = the data from the desired bit, an array of ones and zeros for each wind vector cell
%%%% Example
%%%% [meaning,data]=read_qs_bit('qs_l2b_23715_v4.0_200401080705.nc','flags',6) yields

%%% Check to make sure varname is 'flags' or 'eflags'
if(~strcmp(varname,'flags') & ~strcmp(varname,'eflags'))
meaning='Bad varname input to read_qs_bit';
%%% Check to make sure bit_number is between an integer 0 and 15
if( bit_number<0 | bit_number>15 | round(bit_number)~=bit_number)
meaning='Bad bit_number input to read_qs_bit';

%%% Check to make sure filename exists
meaning='Bad filename input to read_qs_bit';
%%% read desired flag variable

%%% determine desired bit mask

%%% read and parse flag meanings and flag masks attributes from variable
[token,remain] = strtok(remain, ' ');
[token,remain] = strtok(remain, 's, ');
masks = [masks , str2num(token)];

%%% find mask in list of assigned masks
%%% if desired bit mask is not in the list return meaning='undefined_bit' and data=[];
if (isempty(i))
%%% otherwise select the right meaning for the desired bit mask

%%% get data from bit

%%% end of function
Posts: 3
Joined: Tue Jul 03, 2018 4:10 pm

Re: QuikSCAT user guide for version 4.0 data?

Postby tomk80 » Mon Jul 09, 2018 10:57 am

Here is a summary of the various flags, from a presentation Dr. Stiles gave at the most recent vector winds meeting:

"flags" LongName "Wind Vector Cell Quality Flags"
Bit 0: name adequate_sigma0_flag Fewer than 4 sigma-0 values in wind vector cell, winds not retrieved
Bit 1: name adequate_azimuth_diversity_flag Less than 20 degrees of azimuth diversity, winds not retrieved
Bit 2: name undefined_bit
Bit 3: name undefined_bit
Bit 4: name undefined_bit
Bit 5: name poor_coastal_processing_flag Currently never set (unless wind is not retrieved)
Bit 6: name wind_retrieval_likely_corrupted_flag Recommended flag, flags 3% of data when either sea_ice, or rain is present.
Bit 7: name coastal_flag At least one measurement in wind vector cell within 20 km of land.
Bit 8: name ice_edge_flag At least one measurement in cell determined to be sea-ice contaminated
Bit 9: name winds_not_retrieved_flag No wind vector retrieved
Bit 10: name high_wind_speed_flag Retrieved wind speed greater than 30 m/s
Bit 11: name low_wind_speed_flag Retrieved wind speed less than 3 m/s
Bit 12: name rain_impact_flag_not_usable_flag Rain impact (IMUDH) flag is not computed, presence of rain unknown
Bit 13: name rain_impact_flag Rain impact (IMUDH) flag, rain detected in cell
Bit 14: name missing_look_flag At least one of the four azimuth looks is unavailable for this cell
Bit 15: name undefined_bit

"eflags" LongName "Extended Wind Vector Cell Quality Flags"
Bit 0: name rain_correction_not_applied_flag Rain correction was not applied, this is typical when no rain is present
Bit 1: name correction_produced_negative_spd_flag Rain correction produced a negative speed
Bit 2: name all_ambiguities_contribute_to_nudging_flag All of the ambiguities in the cell were used during nudging
Bit 3: name large_rain_correction_flag Rain correction to wind speed was larger than 1.0 m/s
Bit 4: name coastal_processing_applied_flag Wind vector cell is close to the coast and coastal processing was performed.
Bit 5: name undefined_bit
Bit 6: name undefined_bit
Bit 7: name undefined_bit
Bit 8: name rain_nearby_flag Rain detected within 50 km of cell.
Bit 9: name ice_nearby_flag Sea ice detected within 50 km of cell
Bit 10: name significant_rain_correction_flag Rain speed correction was larger than 0.1 m/s
Bit 11: name rain_correction_applied_flag Rain correction was applied, inverse of bit 0.
Bit 12: name wind_retrieval_possibly_corrupted_flag Strict flag, flags 15% of data with rain or sea ice is nearby or coastal processing performed
Bit 13: name undefined_bit
Bit 14: name undefined_bit
Bit 15: name undefined_bit
Posts: 3
Joined: Tue Jul 03, 2018 4:10 pm

Return to General Questions