haddock.modules.analysis.alascan.scan module

alascan module.

class haddock.modules.analysis.alascan.scan.Scan(model_list, output_name, core, path, **params)[source]

Bases: object

Scan class.

output()[source]

Write down unique contacts to file.

run()[source]

Run alascan calculations.

class haddock.modules.analysis.alascan.scan.ScanJob(output, params, scan_obj)[source]

Bases: object

A Job dedicated to the parallel alanine scanning of models.

run()[source]

Run this ScanJob.

haddock.modules.analysis.alascan.scan.add_delta_to_bfactor(pdb_f, df_scan)[source]

Add delta scores as b-factors.

Parameters:
  • pdb_f (str) – Path to the pdb file.

  • df_scan (pandas.DataFrame) – Dataframe with the scan results for the model

Returns:

pdb_f (str) – Path to the pdb file with the b-factors added.

haddock.modules.analysis.alascan.scan.add_zscores(df_scan_clt, column='delta_score')[source]

Add z-scores to the dataframe.

Parameters:
  • df_scan (pandas.DataFrame) – Dataframe with the scan results for the model.

  • colunm (str) – Column to calculate the z-score.

Returns:

df_scan (pandas.DataFrame) – Dataframe with the z-scores added.

haddock.modules.analysis.alascan.scan.alascan_cluster_analysis(models)[source]

Perform cluster analysis on the alascan data.

Parameters:
  • models (list) – List of models.

  • path (str) – Path to the run directory.

haddock.modules.analysis.alascan.scan.calc_score(pdb_f, run_dir)[source]

Calculate the score of a model.

Parameters:
  • pdb_f (str) – Path to the pdb file.

  • run_dir (str) – Path to the run directory.

Returns:

  • score (float) – Haddock score.

  • vdw (float) – Van der Waals energy.

  • elec (float) – Electrostatic energy.

  • desolv (float) – Desolvation energy.

  • bsa (float) – Buried surface area.

haddock.modules.analysis.alascan.scan.create_alascan_plots(clt_alascan, scan_residue, offline=False)[source]

Create the alascan plots.

haddock.modules.analysis.alascan.scan.generate_alascan_output(models, path)[source]

Generate the alascan output files.

Parameters:
  • models (list) – List of models.

  • path (str) – Path to the run directory.

haddock.modules.analysis.alascan.scan.get_score_string(pdb_f, run_dir)[source]

Get score output from cli_score.main.

Parameters:
  • pdb_f (str) – Path to the pdb file.

  • run_dir (str) – Path to the run directory.

Returns:

out (list) – List of strings with the score output.

haddock.modules.analysis.alascan.scan.mutate(pdb_f, target_chain, target_resnum, mut_resname)[source]

Mutate a residue in a PDB file into a different residue.

Parameters:
  • pdb_f (str) – Path to the pdb file.

  • target_chain (str) – Chain of the residue to be mutated.

  • target_resnum (int) – Residue number of the residue to be mutated.

  • mut_resname (str) – Residue name of the residue to be mutated.

Returns:

mut_pdb_fname (str) – Path to the mutated pdb file.