structuralTendencyPlot: Plotting Structural Tendency of Amino Acid Sequence

Description Usage Arguments Value Plot Colors References See Also Examples

View source: R/structuralTendency.R

Description

Convenient graphing for the structuralTendency function.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
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"

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

 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
37
38
39
40
41
42
43
#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)

Example output

  AA           Tendency Total Frequency
1  A Disorder Promoting     1         5
2  C    Order Promoting     1         5
3  D   Disorder Neutral     1         5
4  E Disorder Promoting     1         5
5  F    Order Promoting     1         5
6  G Disorder Promoting     1         5

idpr documentation built on Dec. 26, 2020, 6 p.m.