catalight.analysis.tools.build_results_dict

catalight.analysis.tools.build_results_dict(file_list, data_labels, reactant, target)

Generate a results dictionary of X/S and data labels for paths given.

Results dict contains [X, S, X Error, S Error] for given datasets and labels typically for use with plotting.

Parameters:
  • file_list (list of str) – List of file paths to experiment folders or experiment log paths then used to initiate experiment objects and calculate conversion and selectivity.

  • data_labels (list of str) – List of data labels used for generating plot legends.

  • reactant (str) – String identity of reactant molecule to track. Must match what exists in the calibration file exactly.

  • target (str) – String identity of the target to use when calculating selectivity. Must match what exists in the calibration file exactly.

Returns:

Dictionary of results (produced by calculate_X_and_S) in the form {data label: result} where data label is a string with the desired legend label and result is a pandas.DataFrame with column headers [‘Conversion’, ‘Selectivity’, ‘X Error’, ‘S Error’] This function is most easily used in conjunction with DataExtractor such as in the run_plot_comparison script.

Return type:

dict