set_pkb_conditions(**kwargs)

Set the parameters that controls the algorithm of function automatic_peak_background_search.

Parameters:
  • kwargs – optional arguments.

  • kwargs['pk_th'] (float) – peak threshold (default = 0.02).

  • kwargs['sh_th'] (float) – shoulder threshold (default = 2.0).

  • kwargs['bg_th'] (float) – background threshold (default = 0.05).

  • kwargs['peak_kind'] (int) – 1: single peak | 2: doublet (Cu-ka) | 3: doublet (Mo-ka) | 4: doublet (Co-ka), (default = 1).

  • kwargs['iter'] (int) – Number of iterations (default = 3).

Returns:

None.

>>> from pycrysfml import cfml_bckpeaks
>>> cfml_bckpeaks.set_pkb_conditions(pk_th=1.0,iter=5)
>>> pkb = cfml_bckpeaks.get_pkb_conditions()
>>> for k in pkb:
...   print(f'{k:>14}: {pkb[k]}')
...
        fortran_type: peak_search_cond_type
      peak_threshold: 1.0
  shoulder_threshold: 2.0
       bkg_threshold: 0.05000000074505806
         kindofpeaks: 1
          iterations: 5