Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions scripts/run/clustering.py
Original file line number Diff line number Diff line change
Expand Up @@ -604,8 +604,9 @@ def run_clustering(input_path,
init_mutabilities_module(mutab_config)
seq_df = seq_df[seq_df["Reference_info"] == 1]
seq_df['Exons_coord'] = seq_df['Exons_coord'].apply(eval)
genes_to_process = [gene for gene in genes_to_process if gene in seq_df["Gene"].unique()]
genes_not_mutability = [gene for gene in genes_to_process if gene not in seq_df["Gene"].unique()]
genes_in_seq_df = set(seq_df["Gene"].unique())
genes_not_mutability = [gene for gene in genes_to_process if gene not in genes_in_seq_df]
genes_to_process = [gene for gene in genes_to_process if gene in genes_in_seq_df]
logger.debug("Computing probabilities..")
miss_prob_dict = get_miss_mut_prob_dict(mut_rate_dict=None, seq_df=seq_df,
mutability=True, mutability_config=mutab_config)
Expand All @@ -615,7 +616,7 @@ def run_clustering(input_path,
result_gene = pd.DataFrame({"Gene" : genes_not_mutability,
"Uniprot_ID" : np.nan,
"F" : np.nan,
"Mut_in_gene" : np.nan,
"Mut_in_gene" : genes.loc[genes_not_mutability].values,
"Ratio_not_in_structure" : np.nan,
"Ratio_WT_mismatch" : np.nan,
"Mut_zero_mut_prob" : np.nan,
Expand Down