save_stacked_screen: Create and save full dye screen, sub-plotted by assignment

View source: R/save_dye_screen_figs.R

save_stacked_screenR Documentation

Create and save full dye screen, sub-plotted by assignment

Description

Creates a plot object, and saves a figure, containing raw data for all screened dyes in all measured fluorescent channels. Results are divided into three subplots, containing dyes which are declared hits, sensitives, and neither (or "none"). Each dye is represented in a single wrapped facet, and both protein and buffer data are displayed.

Usage

save_stacked_screen(tidied_screen, hits, ratio_marg = 190/110, ...)

Arguments

tidied_screen

a tibble containing raw data from a dye screen, both protein and buffer, e.g. as output by the tidy_dye_screen() function.

hits

a tibble containing hit assignments for each dye. Must have columns "dye" and "assignment", described below:

  • "dye", a character column containing the names of all of the dyes tested in the experiment. In order for a dye to be displayed in this plot, its name in this dataframe must match its name in the tidied_screen dataframe exactly. Matches are case- and punctuation-sensitive. (e.g. a dye named "L045" in this tibble will match only to a dye named "L045" in the tidied_screen tibble; it will not match to "l045", "L45", "L-045", etc.).

  • "assignment", a character column containing the assignment of how a given dye behaved with screened protein. These assignments must be supplied by the user. Assignments can be determined either manually, or with assistance using the hit-calling tools in this package (in development as of August 2021). Possible assignments are: "hit", "sensitive", and "none", which correspond to the following judgements:

    • "hit", any dye which appears to detect the melting of the protein of interest, while having minimal temperature-sensitive fluorescence in the absence of protein.

    • "sensitive", a less stringent category than 'hit'. Useful for dyes where definition as a "hit" isn't quite warranted, but which demonstrating some fluorescent response to the protein (over buffer) which could be potentially interesting. Common reasons for a a dye to receive a "senstive" assignment detection of non-cannonical transitions, and/or detecting a cannonical transtion, but doing so with far weaker signal than dyes called as 'hits'. In particular, the "sensitive" assignment is useful for flagging dyes which may be interesting for follow-up later, or fleshing out SAR of the hit dyes for a given protein.

    • "none", an assignment given to dyes which showed no major difference between a DSF run with or without the protein, suggesting no fluorescent response to the protein of interest at any temperature.

ratio_marg

a number, giving the ratio between the total size of a facet's plot panel and the their facet panel, inclusive of borders, axis ticks, etc. Ideally this could be reliably extracted from the plot object itself in a future version of this package. Is greater than one.

...

additional arguments, passed to the make_figure_title() and saved_stacked_plots() functions. See documentation for the make_figure_title() and saved_stacked_plots() functions for possible options, which include assigning a directory to which to write the plot object created, and requesting the plot be saved using a specific the graphics device (default is "pdf" but all extentions compatible with ggsave() can be used).

Details

This plot is closely related to the one created by the save_stacked_screen() function, but differs in that only "hit" and "sensitive" dyes are displayed. Unlike the plot generated by save_stacked_hits(), all channels are displayed within a single facet.

This function is often accessed through it's wrapper function, save_dye_screen_figs(), though it can be used identically on it's own. See the documentation of the save_dye_screen_figs() function for more information on what each of these four plots display.

Value

if assigned to an object, returns a ggproto object. Always saves a figure to the current working directory, or the directory specified through arguments to ...


taiawu/dsfworld_package documentation built on June 18, 2024, 5:39 a.m.