Samples not plotted
Closed this issue · 2 comments
Dear @acvill,
really nice Shiny app you did but I've some problems to plot all my samples (see below). I'm really not sure what's the issue here? When I open the samples that not get plotted by bracken_plot
in Pavian, I see that those samples actually have reads assigned, in some cases a lot. Find here
the output of combine_bracken_outputs.py
and the kraken2
report files.
Cheers Bastian
Hi @acvill,
may the problem be that some samples do not have any reads assigned to the species level? However, this doesn't apply for every sample which aren't plotted above; some of which have more than 10 reads assigned to a certain species but still are not plotted.
Cheers Bastian
Hi Bastian,
Thanks for using bracken_plot. I took a look at your combined species-level bracken report, and it appears that some of your sample columns indeed sum to zero.
readr::read_tsv(file = "MIDORI2_GB261_0.2_S.txt", col_names = TRUE) |>
tidyr::pivot_longer(cols = -c("name","taxonomy_id","taxonomy_lvl"), names_to = "sample") |>
dplyr::filter(!grepl("_num", sample)) |>
dplyr::mutate(sample = gsub("_frac","",sample)) |>
dplyr::group_by(sample) |>
dplyr::summarize(sum = sum(value)) |>
dplyr::filter(sum == 0) |>
dplyr::pull(sample)
[1] "WAL-F-1" "WAL-F-3" "WAL-F-4" "WAL-F-5" "WAL-L-1" "WAL-L-2" "WAL-L-5" "WEI-AH-1" "WEI-AH-2" "WEI-AH-3" "WEI-AH-4" "WEI-AH-5"
[13] "WEI-F-1" "WEI-F-2" "WEI-F-3" "WEI-F-4" "WEI-F-5" "WEI-L-1" "WEI-L-2" "WEI-L-3" "WEI-L-5" "ZIE-AH-2" "ZIE-AH-3" "ZIE-AH-5"
[25] "ZIE-F-1" "ZIE-F-2" "ZIE-F-3" "ZIE-F-4" "ZIE-F-5" "ZIE-L-1" "ZIE-L-2" "ZIE-L-3" "ZIE-L-4" "ZIE-L-5"
Best,
Albert