Description Usage Arguments Details Value See Also Examples
View source: R/plot_kinetics.R
Plots kinetics of the hydrogen-deuterium exchange for specific peptides.
1 | plot_kinetics(kin_dat, theoretical = FALSE, relative = TRUE)
|
kin_dat |
calculated kinetic data by |
theoretical |
|
relative |
|
This function visualises the output of the
calculate_kinetics
function.
Based on supplied parameters appropriate columns are chosen for the plot.
The uncertainty associated with each peptide is shown as a ribbon.
Axis are labeled according to the supplied parameters but no title is provided.
If you want to plot data for more then one peptide in one state, join
calculated data by using bind_rows
from dplyr package and
pass the result as kin_dat.
a ggplot
object.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | # load example data
dat <- read_hdx(system.file(package = "HaDeX", "HaDeX/data/KD_180110_CD160_HVEM.csv"))
# calculate data for the sequence INITSSASQEGTRLN in the CD160 state
(kin1 <- calculate_kinetics(dat,
protein = "db_CD160",
sequence = "INITSSASQEGTRLN",
state = "CD160",
start = 1,
end = 15,
time_in = 0.001,
time_out = 1440))
# calculate data for the sequence INITSSASQEGTRLN in the CD160_HVEM state
(kin2 <- calculate_kinetics(dat,
protein = "db_CD160",
sequence = "INITSSASQEGTRLN",
state = "CD160_HVEM",
start = 1,
end = 15,
time_in = 0.001,
time_out = 1440))
# load extra packages
library(dplyr)
# plot a single peptide - theoretical and relative
plot_kinetics(kin_dat = kin1,
theoretical = TRUE,
relative = TRUE)
# plot joined data - experimental and absolute
bind_rows(kin1, kin2) %>%
plot_kinetics(theoretical = FALSE,
relative = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.