Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Excerpt
hiddentrue

Each element in the data section of a BUFR can be missing.ecCodes provides a simple way for the user to check if the value of an element is missing by comparing with two constants

Missing values

Step-by-step guide

Each element in the data section of a BUFR can be missing.

ecCodes provides a simple way for the user to check if the value of an element is missing by comparing with two constants:

Code Block
CODES_MISSING_LONG

...


CODES_MISSING_DOUBLE

The constants are available in Python, Fortran 90 and C and the user needs to compare with the appropriate constant depending on the type of the variable used. This is an example of Fortran 90 code:      

Code Block
!declare backscatter as double precision

...



real(kind=8), dimension(:), allocatable :: backscatter
 
!get the values
call codes_get(ibufr,'/beamIdentifier=2/backscatter',backscatter);
do i=1,size(backscatter)
    !compare with double precision missing
    if (backscatter(i)/=CODES_MISSING_DOUBLE) then
        !process non missing values
    else
        !process missing values
    endif
end do

Content by Label
showLabelsfalse
max5
spaces~usa
showSpacefalse
sortmodified
reversetrue
typepage
cqllabel = "kb-how-to-article" and type = "page" and space = "UDOC"
labelskb-how-to-article

...