Learn R Programming

DrDimont (version 0.1.4)

determine_drug_targets: Determine drug target nodes in network

Description

Finds node IDs of network nodes in `graphs` that are targeted by a drug in `drug_target_interactions`. Returns list of node ids and list of adjacent edges.

Usage

determine_drug_targets(graphs, annotations, drug_target_interactions, settings)

Value

A named list with elements `targets` and `edgelists`. `targets` is a named list with elements `target_nodes` and `drugs_to_target_nodes`. `target_nodes` is a data frame with column `node_id` (unique node IDs in the iGraph object targeted by drugs) and columns `groupA` and `groupB` (bool values specifying whether the node is contained in the combined graph of the group). Element `drugs_to_target_nodes` contains a named list mapping drug names to a vector of their target node IDs. `edgelists` contains elements `groupA` and `groupB` containing each a list of edges adjacent to drug target nodes.

Arguments

graphs

[list] A named list with elements `groupA` and `groupB` containing the combined graphs of each group as iGraph object (`graphs` from output of generate_combined_graphs)

annotations

[list] List of data frames that map node IDs to identifiers. Contains `both` with unique identifiers across the whole data (output of generate_combined_graphs)

drug_target_interactions

[list] Named list specifying drug target interactions for drug response score computation

settings

[list] A named list containing pipeline settings. The settings list has to be initialized by drdimont_settings. Items in the named list can be adjusted as desired.

Examples

Run this code
data(drug_gene_interactions)
data(combined_graphs_example)

example_settings <- drdimont_settings()

example_drug_target_interactions <- make_drug_target(target_molecules='protein',
                                        interaction_table=drug_gene_interactions,
                                        match_on='gene_name')

example_drug_target_edges <- determine_drug_targets(
                                 graphs=combined_graphs_example$graphs,
                                 annotations=combined_graphs_example$annotations,
                                 drug_target_interactions=example_drug_target_interactions,
                                 settings=example_settings)

Run the code above in your browser using DataLab