Create Interpro profile

knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

A common practice to annotate the genes of a new genome or reconstructed genome is to use InterProScan. Here are some functions to explore that information.

First, load the rbims package.

install_github("mirnavazquez/RbiMs", force = T)
library(rbims)

The function to use that information is read_interpro. This function can parse the information of the PFAM, INTERPRO, and KEGG ids. The KEGG analysis is just possible if InterProScan was run with the -pa option. Two output options are also possible: a wide profile, or a long table.

If you want to follow the example you can download the use rbims test file.

interpro_pfam_profile<-read_interpro(data_interpro = "Interpro_test.tsv", database="Pfam", profile = T)
head(interpro_pfam_profile)

Or print a long table profile = F.

interpro_pfam_long<-read_interpro("Interpro_test.tsv", database="Pfam", profile = F)
head(interpro_pfam_long)

You can export this to a table like this:

write.table(interpro_pfam_long, "Interpro.tsv", quote = F, sep = "\t", row.names = F, col.names = T)

Or setting write write = T.



mirnavazquez/RbiMs documentation built on Sept. 6, 2024, 1:05 p.m.