# HG changeset patch # User davidvanzessen # Date 1461144765 14400 # Node ID 67a9ddf6a8f599a061a4ae8088de42443dcf0d2c # Parent 88e0e7665086db2a0e8b9c31b629f492169d486d Uploaded diff -r 88e0e7665086 -r 67a9ddf6a8f5 aa_histogram.r --- a/aa_histogram.r Wed Apr 06 05:54:13 2016 -0400 +++ b/aa_histogram.r Wed Apr 20 05:32:45 2016 -0400 @@ -29,6 +29,10 @@ print("---------------- plot ----------------") +#also need these two, I don't even know... +print(paste("dat_freq", length(dat_freq))) +print(paste("dat_dt", nrow(dat_dt))) + m = ggplot(dat_dt, aes(x=i, y=freq)) + theme(axis.text.x = element_text(angle = 90, hjust = 1)) m = m + geom_histogram(stat="identity", colour = "black", fill = "darkgrey", alpha=0.8) + scale_x_continuous(breaks=1:length(dat_freq), labels=1:length(dat_freq)) m = m + annotate("segment", x = 0.5, y = -0.05, xend=26.5, yend=-0.05, colour="darkgreen", size=1) + annotate("text", x = 13, y = -0.1, label="FR1") diff -r 88e0e7665086 -r 67a9ddf6a8f5 merge_and_filter.r --- a/merge_and_filter.r Wed Apr 06 05:54:13 2016 -0400 +++ b/merge_and_filter.r Wed Apr 20 05:32:45 2016 -0400 @@ -59,10 +59,13 @@ unmatched=summ[NULL,c("Sequence.ID", "chunk_hit_percentage", "nt_hit_percentage", "start_locations", "best_match")] -if(any(higher_than)){ +if(!all(higher_than)){ #check for not all because that would mean the unmatched set is empty unmatched = summ[!higher_than,] unmatched = unmatched[,c("Sequence.ID", "chunk_hit_percentage", "nt_hit_percentage", "start_locations", "best_match")] unmatched$best_match = paste("unmatched,", unmatched$best_match) +} + +if(any(higher_than)){ summ = summ[higher_than,] } print(paste("Number of matched sequences:", nrow(summ)))