watex.utils.coreutils.parseDCArgs#
- watex.utils.coreutils.parseDCArgs(fn, delimiter=None, arg='stations')[source]#
Parse DC stations and search arguments from file and output to array accordingly.
The froms argument is the depth in meters from which one expects to find a fracture zone outside of pollutions. Indeed, the fromS parameter is used to speculate about the expected groundwater in the fractured rocks under the average level of water inrush in a specific area. For more details refer to
watex.methods.electrical.VerticalSounding.fromSdocumentation.- Parameters:
fn – path-like object, full path to DC station or fromS file. if data is considered as a station file, it must be composed the station names. Commonly it can be used to specify the selected station of all DC-resistity line where one expects to locate the drilling. Conversly, the fromS file should not include any letter so if given, ot sould be removed.
arg – str of the attribute of the DC methods.Any other value except
stationshould considered asfromSvalue and will parse the file accordingly.delimiter –
str , delimiter to separate the different stations or ‘fromS’ value. For instance, use use < delimiter=’ ‘> when all values are separated with space and be arranged in the same line like:
>>> 'S02 S12 S12 S15 S28 S30' # line of the file.
- Returns:
array: array of station name.
- Note:
if all station prefixes belong to the module station property object i.e
watex.property.P.istation, the prefix should be overwritten to only keep the S. For instance ‘pk25’-> ‘S25’- Example:
>>> from watex.utils.coreutils import parseDCArgs >>> sf='data/sfn.txt' # use delimiter if values are in the same line. >>> sdata= parseDCArgs(sf) >>> sdata ... >>> # considered that the digits in the file correspond to the depths >>> fdata= parseDCArgs(sf, arg='froms') >>> fdata ...