structuralTendencyPlot: Plotting Structural Tendency of Amino Acid Sequence

View source: R/structuralTendency.R

structuralTendencyPlotR Documentation

Plotting Structural Tendency of Amino Acid Sequence

Description

Convenient graphing for the structuralTendency function.

Usage

structuralTendencyPlot(
  sequence,
  graphType = "pie",
  summarize = FALSE,
  proteinName = NA,
  alphabetical = FALSE,
  disorderPromoting = c("P", "E", "S", "Q", "K", "A", "G"),
  disorderNeutral = c("D", "T", "R"),
  orderPromoting = c("M", "N", "V", "H", "L", "F", "Y", "I", "W", "C"),
  ...
)

Arguments

sequence

amino acid sequence (or pathway to a fasta file) as a character string. Supports multiple sequences / files, as a character vector of strings.

graphType

character string, required. graphType must be set to c("pie", "bar", "none"). When graphType = "pie", the output is a pie chart. When graphType = "bar", the output is a bar chart. When graphType = "none", the output is the data frame that would otherwise be used to plot the data.

summarize

logical value, FALSE by default. When summarize = TRUE, each residue is aggregated into Disorder Tendency Groups. (See structuralTendency for more details). When summarize = FALSE, residue identity is preserved, and the output is colored by Disorder Tendency Groups.

proteinName,

optional character string. NA by default. Used to either add the name of the protein to the plot title.

alphabetical

logical value, FALSE by default. Order of residues on plot axis. Only relevant when summarize = FALSE, otherwise is ignored. If FALSE, ordering is grouped by Disorder Tendency (P, E, S, ..., W, C). If TRUE, the residues are ordered alphabetically (A, C, D, E, ..., W, Y).

disorderPromoting, disorderNeutral, orderPromoting

character vectors of individual residues to be matched with the input sequence. Defaults:

  • disorderPromoting = c("P", "E", "S", "Q", "K", "A", "G")

  • orderPromoting = c("M", "N", "V", "H", "L", "F", "Y", "I", "W", "C")

  • disorderNeutral = c("D", "T", "R")

It is not recommended to change these.

...

additional arguments to be passed to structuralTendency and ggplot

Value

a data frame containing each residue from the sequence matched with its structural tendency, defined by disorderPromoting, disorderNeutral, and orderPromoting.

Plot Colors

For users who wish to keep a common aesthetic, the following colors are used when graphType = "bar" or "pie"

  • Disorder Neutral = "#F0B5B3"

  • Disorder Promoting = "darkolivegreen3" or "#A2CD5A"

  • Order Promoting = "darkorchid1" or "#BF3EFF"

References

Uversky, V. N. (2013). A decade and a half of protein intrinsic disorder: Biology still waits for physics. Protein Science, 22(6), 693-724. https://doi.org/10.1002/pro.2261.
Kulkarni, Prakash, and Vladimir N. Uversky. "Intrinsically disordered proteins: the dark horse of the dark proteome." Proteomics 18.21-22 (2018): 1800061. https://doi.org/10.1002/pmic.201800061.

See Also

Other structural tendency: structuralTendency()

Examples

#Amino acid sequences can be character strings
aaString <- "ACDEFGHIKLMNPQRSTVWY"
#Amino acid sequences can also be character vectors
aaVector <- c("A", "C", "D", "E", "F",
              "G", "H", "I", "K", "L",
              "M", "N", "P", "Q", "R",
              "S", "T", "V", "W", "Y")
#Alternatively, .fasta files can also be used by providing
##The path to the file as a character string
structuralTendencyPlot(aaString)
structuralTendencyPlot(aaVector)

#The plot can be a pie chart (default)
structuralTendencyPlot(aaString,
                    graphType = "pie")

#Or the plot can be a bar graph
structuralTendencyPlot(aaString,
                    graphType = "bar")

#To display general tendency rather than residues, set summarize = T
structuralTendencyPlot(aaString,
                    graphType = "pie",
                    summarize = TRUE)

structuralTendencyPlot(aaString,
                    graphType = "bar",
                    summarize = TRUE)

#If you wish to export this as a dataframe, set graphType = "none"
exampleDF <- structuralTendencyPlot(aaString,
                                  graphType = "none")
head(exampleDF)

#If using a different definition of disordered residues
##These residues are labeled as such from Dunker et al (2001),
##"Intrinsically disordered protein."
structuralTendencyPlot(aaString,
              disorderPromoting = c("A", "R", "G", "Q", "S", "P", "E", "K"),
              disorderNeutral = c("H", "M", "T", "D"),
              orderPromoting = c("W", "C", "F", "I", "Y", "V", "L", "N"),
              graphType = "bar",
              alphabetical = TRUE)

wmm27/idpr documentation built on Jan. 12, 2023, 8:45 a.m.