Data extraction module#

The data extraction allows to retrieve kinetic data from one or multiple files.

In addition to retrieving data from .txt or .csv files, this module also check the validity of provided data.

Note

To improve computational costs, the data is retrieved as numpy arrays.

data_extraction.extract_dsc_data_multiple_files(file_paths, delimiter=',', has_header=False, skip_lines=0)[source]#

Extract DSC data from multiple txt or csv files and perform data validation.

Parameters:
  • file_paths (list) – List of file paths to input txt or csv files containing DSC data.

  • delimiter (str, optional) – Delimiter used in the input files. Default is ‘,’.

  • has_header (bool, optional) – Whether the input files have headers. Default is False.

  • skip_lines (int, optional) – Number of lines to skip at the beginning of each file. Default is 0.

Returns:

(time, temperature, rate_of_reaction, extent_of_reaction)

Return type:

Tuple of concatenated numpy arrays

data_extraction.extract_dsc_data_single_file(file_path, delimiter=',', has_header=False, skip_lines=0)[source]#

Extract DSC data from multiple txt or csv files and perform data validation.

Parameters:
  • file_path (list) – File path to input txt or csv files containing DSC data.

  • delimiter (str, optional) – Delimiter used in the input file. Default is ‘,’.

  • has_header (bool, optional) – Whether the input file has headers. Default is False.

  • skip_lines (int, optional) – Number of lines to skip at the beginning of the file. Default is 0.

Returns:

(time, temperature, rate_of_reaction, extent_of_reaction)

Return type:

Tuple of numpy arrays