R/SequenceLengthDistributionPlot.R

Defines functions SequenceLengthDistributionPlot

Documented in SequenceLengthDistributionPlot

#' SequenceLengthDistributionPlot
#'
#' @param input_data result tables folder
SequenceLengthDistributionPlot <- function(input_data) {
  df.seq.read.length <- 
    read.csv(file = file.path(
      input_data, "Sequence_length_distribution.csv"))
  ggplot2::ggplot(data=df.seq.read.length,
                  ggplot2::aes_string(x="width", y="percentage", group = "filename")) +
    ggplot2::geom_line(mapping = ggplot2::aes_string(colour = "filename")) +
    ggplot2::geom_point() +
    ggplot2::labs(x = "position in read (bp)", y = "Read (%)") +
    ggplot2::theme_bw() +
    ggplot2::ggtitle("Sequence length distribution") +
    ggplot2::theme(axis.text.x = ggplot2::element_text(size = 5),
                   plot.title = ggplot2::element_text(hjust = 0.5))
}

Try the inDAGO package in your browser

Any scripts or data that you put into this service are public.

inDAGO documentation built on Aug. 8, 2025, 7:47 p.m.