calculate_polya_stats: Calculates basic statistics for polya lengths

View source: R/polya_stats.R

calculate_polya_statsR Documentation

Calculates basic statistics for polya lengths

Description

Takes polyA predictions table as input and checks if there is significant difference in polyA lengths between chosen conditions for each transcript. By default, Wilcoxon Rank Sum (wilcox.test) test is used.

Usage

calculate_polya_stats(
  polya_data,
  transcript_id_column = "transcript",
  min_reads = 0,
  grouping_factor = "sample_name",
  condition1 = NA,
  condition2 = NA,
  stat_test = "Wilcoxon",
  alpha = 0.05,
  add_summary = TRUE,
  length_summary_to_show = "gm_mean",
  ...
)

Arguments

polya_data

input table with polyA predictions

transcript_id_column
  • name of the column with transcript ids (default = "transcript")

min_reads

minimum number of reads to include transcript in the analysis

grouping_factor

which column defines groups (default: sample_name)

condition1

if grouping_factor has more than 2 levels, which level use for comparison

condition2

if grouping_factor has more than 2 levels, which level use for comparison

stat_test

what statistical test to use for testing, currently supports "Wilcoxon" (for wilcox.test), "KS" (for ksTest from FSA package) or "glm" (for glm)

alpha
  • alpha value to consider a hit significant (default - 0.05)

add_summary
  • add summary (mean polya lengths, counts) to statistics results?

length_summary_to_show
  • which length summary to show ("median"/"mean"/"gm_mean")

...
  • additional parameters to pass to .polya_stats (custom_glm_formula,use_dwell_time)

Value

summary table with pvalues and median/mean values associated to each transcript


smaegol/nanotail documentation built on June 29, 2024, 12:35 a.m.