getDrugTarget: getDrugTarget

View source: R/drugTargetAnnotations_Fct.R

getDrugTargetR Documentation

getDrugTarget

Description

This function allows you to query a subset of the data fetched by drugTargetAnnotTable.

Usage

getDrugTarget(dt_file=file.path(config$resultsPath,"drugTargetAnnot.xls"), queryBy=list(molType=NULL, idType=NULL, ids=NULL), 
								  id_mapping=c(chembl="chembl_id", pubchem="PubChem_ID", uniprot="UniProt_ID"), columns,config=genConfig()) 

Arguments

dt_file

The drug target annotation file. This can be generated with drugTargetAnnotTable.

queryBy

A list defining the query, as described in queryBy.

id_mapping

A list providing the id columns for ChEMBL, PubChem, and UniProt. It should contain the fields "chembl", "pubchem", and "uniprot", each wit the column name of the respective id number in the drug target annotation file. See default value above for an example.

columns

A list of column indexes to select as a subset of the final result set.

config

General configuration. See genConfig.

Value

Returns the query result as a data frame.

Author(s)

Thomas Girke

See Also

drugTargetAnnotTable

Examples



		 config = genConfig(chemblDbPath= 
									system.file("extdata", "chembl_sample.db", package="drugTargetInteractions"),
							  resultsPath = 
									system.file("extdata", "results", package="drugTargetInteractions"))
		 id_mapping <- c(chembl="chembl_id", pubchem="PubChem_ID", uniprot="UniProt_ID", drugbank="DrugBank_ID")

		 queryBy <- list(molType="cmp", idType="chembl", ids=c("CHEMBL25", "CHEMBL1742471"))
		 getDrugTarget(queryBy=queryBy, id_mapping=id_mapping,
								 columns=c(1,5,8,16,17),config=config) 

		 queryBy <- list(molType="cmp", idType="pubchem", ids=c("2244", "65869", "2244"))
		 getDrugTarget(queryBy=queryBy, id_mapping=id_mapping,
								 columns=c(1,5,8,16,17),config=config) 

		 queryBy <- list(molType="protein", idType="uniprot", ids=c("P43166", "P00915", "P43166"))
		 getDrugTarget(queryBy=queryBy, id_mapping=id_mapping,
								 columns=c(1,5,8,16,17),config=config)


girke-lab/drugTargetInteractions documentation built on Oct. 10, 2022, 10:35 p.m.