Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Shiny App for comparison of samples and plotting effect size

NotificationsYou must be signed in to change notification settings

JoachimGoedhart/PlotsOfDifferences

Repository files navigation

A Shiny App for comparison of samples

About PlotsOfDifferences

The PlotsOfDifferences Shiny app plots the data, statistics and (optional) differences to enable the comparison of (experimental) conditions. The philosophy of the approach is that plotting the raw data (instead of a summary) improves transparency and interpretationthis blog). To further facilitate the comparison, summary statistics (mean, median, boxplot) and inferential statistics (confidence intervals) can be added. The user has full control over the visibility of the raw data and statistics by adjustment of the transparency (alpha). Finally, differences between central values (mean or median) can be quantified, reflecting effect size. To this end, a reference condition ('control') must be defined, which can be changed by the user. The 95%CI of the difference per condition is calculated from 1000 bootstrap samples (their distribution is shown in the difference plot) of the statistic (mean of median).A table with summary and inferential statistics is provided on a separate tab. There is an option to add a p-value which is calculated by arandomization test.

Bootstrapping is used to calculate the (asymmetric) 95% CI of medians as well as the differences. More information inthis blog

The p-values that are (optionally) listed in the summary table is the output of arandomization test.

The data can be supplied in spreadsheet/long format (e.g. by copy-pasting from excel) or in tidy format. For more information on the conversion of spreadsheet data to tidy data seethis blog.

The differences plot can be saved as a PDF file, which can be opened and edited with Adobe Illustrator to allow for fine adjustments of the lay-out.

More information can be found inthe preprint

Running the App

A shiny server running the app is available:https://huygens.science.uva.nl/PlotsOfDifferences/

The app can also run locally from R/Rstudio:

Give it a quick try by running it directly from Github. In the command line (in R or Rstudio) typeshiny::runGitHub('PlotsOfDifferences', 'JoachimGoedhart')

Or download it to use it offline:

-download the app.R, geom_flat_violin.R and csv files with example data.

-Run RStudio and load app.R

-Select 'Run All' (shortcut is command-option-R on a Mac) or click on "Run App" (upper right button on the window)

This should launch a web browser with the Shiny app.Note that the app depends on several R packages that need to be installed (shiny, ggplot2, dplyr, tidyr, readr, magrittr, ggbeeswarm, readxl, DT, RCurl, gridExtra, shinycssloaders). It also uses geom_flat_violin.R (https://gist.github.com/dgrtwo/eb7750e74997891d7c20)

Credits

PlotsOfData is inspired byBoxPlotR. Seethis link for background information on boxplots.
The code for the shiny app is partially derived fromggplotGUI byGert Stulp
The colorblind safe palettes were developed byPaul Tol.
The display of bootstrap distributions is inspired bywork of Adam Claridge-Chang and colleagues (2017)

PlotsOfData is created and maintained by Joachim Goedhart (@joachimgoedhart) and Marten Postma

Example output

alt text

Counter

HitCount

About

Shiny App for comparison of samples and plotting effect size

Resources

Stars

Watchers

Forks

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp