python/methylnet/model_interpretability.py
def split_hyper_hypo_methylation(shapley_data, output_dir, test_pkl, threshold):
    """Split SHAPleyData object by methylation type (needs to change; but low methylation is 0.5 beta value and below) and output to file."""
    os.makedirs(output_dir,exist_ok=True)
    shapley_data=ShapleyData.from_pickle(shapley_data)
    shapley_data_explorer=ShapleyDataExplorer(shapley_data)
    test_methyl_array=MethylationArray.from_pickle(test_pkl)
    shap_data_methylation=shapley_data_explorer.return_shapley_data_by_methylation_status(test_methyl_array, threshold)
    shap_data_methylation['hypo'].to_pickle(join(output_dir,'hypo_shapley_data.p'))
    shap_data_methylation['hyper'].to_pickle(join(output_dir,'hyper_shapley_data.p'))
Split SHAPleyData object by methylation type (needs to change; but low methylation is 0.5 beta value and below) and output to file.
Split SHAPleyData object by methylation type (needs to change; but low methylation is 0.5 beta value and below) and output to file.
Split SHAPleyData object by methylation type ( needs to change ; but low methylation is 0 . 5 beta value and below ) and output to file .
def split_hyper_hypo_methylation(shapley_data, output_dir, test_pkl, threshold):
    os.makedirs(output_dir,exist_ok=True)
    shapley_data=ShapleyData.from_pickle(shapley_data)
    shapley_data_explorer=ShapleyDataExplorer(shapley_data)
    test_methyl_array=MethylationArray.from_pickle(test_pkl)
    shap_data_methylation=shapley_data_explorer.return_shapley_data_by_methylation_status(test_methyl_array, threshold)
    shap_data_methylation['hypo'].to_pickle(join(output_dir,'hypo_shapley_data.p'))
    shap_data_methylation['hyper'].to_pickle(join(output_dir,'hyper_shapley_data.p'))
def split_hyper_hypo_methylation ( shapley_data , output_dir , test_pkl , threshold ) : os . makedirs ( output_dir , exist_ok = True ) shapley_data = ShapleyData . from_pickle ( shapley_data ) shapley_data_explorer = ShapleyDataExplorer ( shapley_data ) test_methyl_array = MethylationArray . from_pickle ( test_pkl ) shap_data_methylation = shapley_data_explorer . return_shapley_data_by_methylation_status ( test_methyl_array , threshold ) shap_data_methylation [ 'hypo' ] . to_pickle ( join ( output_dir , 'hypo_shapley_data.p' ) ) shap_data_methylation [ 'hyper' ] . to_pickle ( join ( output_dir , 'hyper_shapley_data.p' ) )
Split SHAPleyData object by methylation type (needs to change; but low methylation is 0.5 beta value and below) and output to file.
Split SHAPleyData object by methylation type ( needs to change ; but low methylation is 0 . 5 beta value and below ) and output to file .
"""Split SHAPleyData object by methylation type (needs to change; but low methylation is 0.5 beta value and below) and output to file."""
shapley_data
output_dir
test_pkl
threshold