Exemplo n.º 1
0
def test_no_column_library():
    try:
        os.mkdir("output_plots")
    except:
        pass
    try:
        os.mkdir("output_summary_library")
    except:
        pass

    libraryidentifications_df = pd.read_csv(
        "reference_stats/librarysearch.tsv", sep=None, error_bad_lines=False)
    libraryidentifications_df = libraryidentifications_df[[
        "#Scan#", "Compound_Name", "Smiles", "INCHI"
    ]]
    libraryidentifications_df = libraryidentifications_df.rename(
        columns={
            "Compound_Name": "featurecompoundname",
            "Smiles": "featuresmiles",
            "INCHI": "featureinchi"
        })

    calculate_stats.calculate_statistics(
        "reference_stats/feature_table.csv",
        "reference_stats/metadata.tsv",
        "output_summary_library",
        output_plots_folder="output_plots",
        libraryidentifications_df=libraryidentifications_df)
Exemplo n.º 2
0
def test_no_column():
    try:
        os.mkdir("output_plots")
    except:
        pass
    try:
        os.mkdir("output_summary")
    except:
        pass

    calculate_stats.calculate_statistics("reference_stats/feature_table.csv",
                                         "reference_stats/metadata.tsv",
                                         "output_summary",
                                         output_plots_folder="output_plots")
Exemplo n.º 3
0
def test_column():
    try:
        os.mkdir("output_plots_chosen")
    except:
        pass
    try:
        os.mkdir("output_summary")
    except:
        pass

    calculate_stats.calculate_statistics("reference_stats/feature_table.csv", 
                                        "reference_stats/metadata.tsv", 
                                        None,
                                        "output_summary", 
                                        output_plots_folder="output_plots_chosen",
                                        metadata_column="ATTRIBUTE_sample_type",
                                        condition_first="urine",
                                        condition_second="unknown")
Exemplo n.º 4
0
def test_facet_column():
    try:
        os.mkdir("output_plots_facet")
    except:
        pass
    try:
        os.mkdir("output_summary")
    except:
        pass

    calculate_stats.calculate_statistics("reference_stats/feature_table.csv", 
                                        "reference_stats/metadata.tsv", 
                                        None,
                                        "output_summary", 
                                        output_plots_folder="output_plots_facet",
                                        metadata_column="ATTRIBUTE_sex",
                                        condition_first="male",
                                        condition_second="female",
                                        metadata_facet_column="ATTRIBUTE_disease_stage")