MCPcopy Create free account
hub / github.com/NSLS2/PyXRF / get_eline_name_category

Method get_eline_name_category

pyxrf/model/parameters.py:958–980  ·  view source on GitHub ↗

Returns the category to which `eline_name` belongs: `eline`, `userpeak`, `pileup` or `other`. Parameters ---------- eline_name: str Name to be analyzed Returns ------- str category: one of `("eline", "userpeak

(self, eline_name)

Source from the content-addressed store, hash-verified

956 logger.info(f"The update list of emission lines: {self.result_dict_names}")
957
958 def get_eline_name_category(self, eline_name):
959 """
960 Returns the category to which `eline_name` belongs: `eline`, `userpeak`,
961 `pileup` or `other`.
962
963 Parameters
964 ----------
965 eline_name: str
966 Name to be analyzed
967
968 Returns
969 -------
970 str
971 category: one of `("eline", "userpeak", "pileup" or "other")`
972 """
973 if check_if_eline_supported(eline_name):
974 return "eline"
975 elif eline_name.lower().startswith("userpeak"):
976 return "userpeak"
977 elif "-" in eline_name: # This is specific to currently accepted naming convention
978 return "pileup"
979 else:
980 return "other"
981
982 def _sort_eline_list(self, element_list):
983 """

Callers 7

_manual_inputMethod · 0.95
_generate_param_keysMethod · 0.95
_sort_eline_listMethod · 0.95
plot_current_elineMethod · 0.45

Calls 1

check_if_eline_supportedFunction · 0.85

Tested by

no test coverage detected