Description Usage Arguments Value Examples
Build a SIF table from a logic rule written in a string
1 | build_sif_table_from_rule(rule_str, target, last_and_num = 0)
|
rule_str |
String containing the rule to be parsed |
target |
Name of the node affected by the rule |
last_and_num |
If the rule contains 'and' gates, their numeration will start after the number provided here (default is 0) |
data.frame with the network structure derived from the rule. The column 'sif_str' contains the string that can be written to a file and then read with 'readSIF()' in order to load a CellNOpt compatible network.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | CellNOptR:::build_sif_table_from_rule("B & (C | D)", "A", last_and_num=2)
test_rule <- list()
test_rule[[1]] <- "AMP_ATP | (ATM & ATR) | HIF1 | !(EGFR | FGFR3)"
test_rule[[2]] <- "A & ((B | C) & !(D & E))"
test_rule[[3]] <- "A & B | C"
test_rule[[4]] <- "A & B & C"
test_rule[[5]] <- "A & (B | C)"
test_rule[[6]] <- "(A | B) & (C | D)"
test_rule[[7]] <- "!(C & D) | (E & F)"
test_rule[[8]] <- "(A | B) & (C | !D) & (E | F)"
parsed_rule <- list()
for (i in c(1:length(test_rule))){
parsed_rule[[i]] <- CellNOptR:::build_sif_table_from_rule(test_rule[[i]], "T")
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.