pytups.utils.Parser package
Submodules
pytups.utils.Parser.StandardParser module
- class pytups.utils.Parser.StandardParser.DataFetcher[source]
Bases:
objectStandard parser for fetching and parsing external data files.
- class pytups.utils.Parser.StandardParser.StandardParser(url=None)[source]
Bases:
objectStandardParser encapsulates the complete workflow for downloading and parsing a NOAA text file.
The class maintains attributes such as the URL, file lines, metadata boundaries, extracted variable names, header skip count, parsed data, and the final DataFrame.
- url
The URL of the file to parse.
- Type:
str
- lines
The content of the file split into lines.
- Type:
list of str
- meta_start
The index of the first metadata line.
- Type:
int
- meta_end
The index of the last metadata line.
- Type:
int
- variables
The extracted variable names.
- Type:
list of str
- skip_lines
The number of header lines to skip in the data block.
- Type:
int
- data
The parsed data rows.
- Type:
list of list of str
- df
The constructed DataFrame.
- Type:
pandas.DataFrame