python/methylnet/model_interpretability.py
def regenerate_top_cpgs(shapley_data,n_top_features,output_pkl, abs_val, neg_val):
    """Increase size of Top CpGs using the original SHAP scores."""
    os.makedirs(output_pkl[:output_pkl.rfind('/')],exist_ok=True)
    shapley_data=ShapleyData.from_pickle(shapley_data)
    shapley_data_explorer=ShapleyDataExplorer(shapley_data)
    shapley_data_explorer.regenerate_individual_shap_values(n_top_cpgs=n_top_features,abs_val=abs_val, neg_val=neg_val).to_pickle(output_pkl)
Increase size of Top CpGs using the original SHAP scores.
Increase size of Top CpGs using the original SHAP scores.
Increase size of Top CpGs using the original SHAP scores .
def regenerate_top_cpgs(shapley_data,n_top_features,output_pkl, abs_val, neg_val):
    os.makedirs(output_pkl[:output_pkl.rfind('/')],exist_ok=True)
    shapley_data=ShapleyData.from_pickle(shapley_data)
    shapley_data_explorer=ShapleyDataExplorer(shapley_data)
    shapley_data_explorer.regenerate_individual_shap_values(n_top_cpgs=n_top_features,abs_val=abs_val, neg_val=neg_val).to_pickle(output_pkl)
def regenerate_top_cpgs ( shapley_data , n_top_features , output_pkl , abs_val , neg_val ) : os . makedirs ( output_pkl [ : output_pkl . rfind ( '/' ) ] , exist_ok = True ) shapley_data = ShapleyData . from_pickle ( shapley_data ) shapley_data_explorer = ShapleyDataExplorer ( shapley_data ) shapley_data_explorer . regenerate_individual_shap_values ( n_top_cpgs = n_top_features , abs_val = abs_val , neg_val = neg_val ) . to_pickle ( output_pkl )
Increase size of Top CpGs using the original SHAP scores.
Increase size of Top CpGs using the original SHAP scores .
"""Increase size of Top CpGs using the original SHAP scores."""
shapley_data
n_top_features
output_pkl
abs_val
neg_val