siphon icon indicating copy to clipboard operation
siphon copied to clipboard

Wyoming can clip some long values

Open dopplershift opened this issue 3 years ago • 2 comments

For the following data, the height column ends up incorrectly reading the height values:

from datetime import datetime
from siphon.simplewebservice.igra2 import WyomingUpperAir

df = WyomingUpperAir.request_data(datetime(2021, 1, 5, 12), '03005')

This is because by default read_fwf only looks at the first 100 rows, and for this dataset heights >= 10000m are beyond that number of rows.

dopplershift avatar Jan 23 '21 17:01 dopplershift

The easy fix for this, based on the pandas docs is to pass infer_rows=200.

dopplershift avatar Jan 23 '21 17:01 dopplershift

Can't reproduce this issue - formatting appears correct for the example given, though the import should read

from siphon.simplewebservice.wyoming import WyomingUpperAir

jrleeman avatar Apr 30 '24 01:04 jrleeman