Skip to content
Snippets Groups Projects
Commit 4bec8bee authored by dimit98's avatar dimit98
Browse files

minor changes

parent dc2a8835
Branches
No related tags found
No related merge requests found
......@@ -19,7 +19,6 @@ rule clustering_louvain:
genes = config["clustering"]["genes_to_vis"],
subclustering = config["clustering"]["subclustering"],
clustering_resolution = config["clustering"]["clustering_resolution"],
#subclustering_resolution = config["clustering"]["subclustering_resolution"]
script:
"../scripts/clustering.py"
......@@ -41,7 +40,8 @@ rule specter:
rule clustering_specter:
input:
expand("file_dir/post_vis_data_{downsampling}.h5ad", downsampling=config["downsampling"]["downsampling_method"])
expand("file_dir/post_vis_data_{downsampling}.h5ad", downsampling=config["downsampling"]["downsampling_method"]),
"file_dir/specter_clustering.csv"
output:
"file_dir/post_clustering_specter.h5ad",
"file_dir/annotation_list_specter.npy",
......@@ -60,7 +60,6 @@ rule clustering_specter:
genes = config["clustering"]["genes_to_vis"],
subclustering = config["clustering"]["subclustering"],
clustering_resolution = config["clustering"]["clustering_resolution"],
#subclustering_resolution = config["clustering"]["subclustering_resolution"]
script:
"../scripts/clustering_specter.py"
......
......@@ -63,17 +63,9 @@ result_ent[,FDR:=p.adjust(`Pr(>Chisq)`, 'fdr')]
ent_de = result_ent[result_ent$FDR<as.numeric(snakemake@config[["differential_testing"]][["DE_threshold"]]),, drop=F]
ent_de = ent_de[order(ent_de$FDR),]
print("hier kommt DE_threshold")
print(as.numeric(snakemake@config[["differential_testing"]][["DE_threshold"]]))
#ent_all = result_ent[order(result_ent$FDR),]
name_of_csv = paste("results/",name,"_diff_testing.csv", sep="")
write.csv(ent_de, name_of_csv, row.names=FALSE)
#name_of_csv2 = paste("results/",name,"_diff_testing.csv", sep="")
#write.csv(ent_all,name_of_csv2, row.names=FALSE)
print("done mit einem Durchlauf")
}
......
library("dplyr")
library("ggplot2")
print(snakemake@wildcards[["cluster"]])
name <- snakemake@wildcards[["cluster"]]
data <- read.csv(file = snakemake@input[[1]])
......
import pandas as pd
from gprofiler import GProfiler
import gprofiler
#import matplotlib.pyplot as plt
#import os
print("EN_threshold")
print(float(snakemake.params.EN_threshold))
print(snakemake.wildcards.cluster)
file = pd.read_csv("results/"+ snakemake.wildcards.cluster +"_diff_testing.csv")
......@@ -19,16 +14,3 @@ enrich_results = enrichment.set_index('native').sort_values('p_value').iloc[:,[2
enrich_results.to_csv("results/"+snakemake.wildcards.cluster+"_enrich_results.csv", sep=",")
#from gprofiler_plotting import plot_enrich
#plt.figure(1)
#heatmap = sb.heatmap(cell_annotation_norm, cbar=False, annot=True)
#heatmap.autoscale()
#heatmap = heatmap.get_figure()
#heatmap.savefig("figures/marker_genes_32_4.png")
#plt.figure(1)
#temp = plot_enrich(paneth_enrich_results)
#temp = temp.get_figure()
#temp.savefig("figures/paneth_enrich_graph.jpg")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment