Learn R Programming

immcp (version 0.9.2)

PrepareData: PrepareData

Description

Prepare input format.

Usage

PrepareData(data, col1, col2, format = "single", sep)

Arguments

data

A data frame containing interaction information.

col1

A charactor containing "drug", "herb", "compound", or "target".

col2

A character containing "drug", "herb", "compound", or "target".

format

one of "single" or "basket".

sep

Separator.

Value

a list

Examples

Run this code
# NOT RUN {
  data("drugSample")
  drug_herb <- PrepareData(drugSample$drug_herb, col1 = "drug", col2 = "herb")
  herb_target <- PrepareData(drugSample$herb_target,
                             col1 = "herb", col2 = "target",
                             format = "basket", sep = ", ")
# }

Run the code above in your browser using DataLab