knitr::opts_chunk$set(echo = TRUE)
This vignette assumes that you have already properly installed rMAUPS.
First, load the rMAUPS package.
library(rMAUPS)
Next, read in protein sequences from uniprot.
uniprot_path <- system.file("extdata", "human_uniprot_seq.txt", package = "rMAUPS") uniprot <- read.delim(uniprot_path, sep='\t') head(uniprot)
Next, search the protein sequences for lysine residues ("K").
lysine_pos <- searchProtSeq(head(uniprot), 'K') head(lysine_pos)
Note, for the sake of a quick example, the above command only searched against the top few protein sequences. Additionally, although not used here, the searchProtSeq function can also handle searching for sequences using regular expression.
First, we'll view all of the lysine residues for KRAS.
# get hits for P01116 id <- 'P01116' start <- lysine_pos[lysine_pos['UniprotId']==id, 'start'] end <- lysine_pos[lysine_pos['UniprotId']==id, 'end'] # view on protein structure browseProtStructure(id, start, end)
Next, we'll compare those to the lysines with reported ubiquitination sites.
# Here, we manually create a dataframe for the KRAS ubiqutination sites. # In the realisitic scenario, you should load the "Ubiquitination_site_dataset" file # from PhosphositePlus DB using the readPSPUbiquitin function. You'll need to download # it your self due to copy protection. id <- 'P01116' ub <- data.frame(gene='KRAS', ID=id, position=c(117, 128, 147)) # get ub sites for P01116 start <- ub[ub['ID']==id, 'position'] end <- ub[ub['ID']==id, 'position'] # view on protein structure browseProtStructure(id, start, end)
sessionInfo()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.