ecmwf / pdbufr

High-level BUFR interface for ecCodes
Apache License 2.0
23 stars 8 forks source link

Support rank notation in ecCodes keys #5

Open sandorkertesz opened 3 years ago

sandorkertesz commented 3 years ago

ecCodes supports the #n#key notation to get the n-th value for a given key in a BUFR message. It would be great if pdbufr allowed for this notation. E.g this code

columns = ["latitude", "longitude", "#1#airTemperature"] 
res = pdbufr.read_bufr(path, columns=columns)

could return only the first airTemperature value from each message in a radiosonde BUFR file.

kozacy commented 3 years ago

i hope pdbufr allowed for this notation,too. case eccodes may use one element more than one time.