nrgpy.read.txt_utils module#

nrgpy.read.txt_utils.format_sympro_site_data(reader)[source]#

adds formatted site dataframe to reader object

class nrgpy.read.txt_utils.read_text_data(filename='', data_type='sp3', txt_dir='', file_filter='', filter2='', file_ext='', sep='\t')[source]#

Bases: object

class for handling known csv-style text data files with header information

Parameters:
filenamestr, optional

perform a single file read (takes precedence over txt_dir)

data_typestr

specify instrument that the data file came from

sepstr

‘ ‘; csv separator

txt_dirstr (path-like)

folder path of text files to read and concatenate

file_filterstr, optional

use when using txt_dir to filter on subset of files

file_extstr, optional

secondary file filter

arrange_ch_info()[source]#

generates list and dataframe of channel information

concat(output_txt=False, out_file='', file_filter='', filter2='', progress_bar=True)[source]#

combine exported rwd files (in txt format)

Parameters:
output_txtbool

set to True to save a concatenated text file

out_filestr

filepath, absolute or relative

file_filterstr
filter2str
progress_barbool
format_rwd_site_data()[source]#

adds formatted site dataframe to reader object

get_data(_file)[source]#

create dataframe of tabulated data

get_head(_file)[source]#

get the first lines of the file

excluding those without tabs up to the self.skip_rows line

get_site_info(_file)[source]#

create dataframe of site info