this function converts the count value of the given node.

update_how(input_graph, node_name, how, knockdown = TRUE)

Arguments

input_graph

The graph object that processed in previous step/s.

node_name

The name of the node whose count is to be changed.

how

The change in terms of fold change.

knockdown

specifies gene knockdown with default TRUE

Value

the graph object.

Details

update_how function calculates the current value of given mirna or gene node on the graph object. User must specify current value as fold change.

Examples

data('minsamp') priming_graph(minsamp, Competing_expression, miRNA_expression)%>% update_how('Gene1',3)
#> Warning: First column is processed as competing and the second as miRNA.
#> # A tbl_graph: 8 nodes and 7 edges #> # #> # A rooted tree #> # #> # Node Data: 8 x 7 (active) #> name type node_id initial_count count_pre count_current changes_variable #> <chr> <chr> <int> <dbl> <dbl> <dbl> <chr> #> 1 Gene1 Competing 1 10000 10000 30000 Up #> 2 Gene2 Competing 2 10000 10000 10000 Competing #> 3 Gene3 Competing 3 5000 5000 5000 Competing #> 4 Gene4 Competing 4 10000 10000 10000 Competing #> 5 Gene5 Competing 5 5000 5000 5000 Competing #> 6 Gene6 Competing 6 10000 10000 10000 Competing #> # … with 2 more rows #> # #> # Edge Data: 7 x 19 #> from to Competing_name miRNA_name Competing_expre… miRNA_expression dummy #> <int> <int> <chr> <chr> <dbl> <dbl> <dbl> #> 1 1 7 Gene1 Mir1 10000 1000 1 #> 2 2 7 Gene2 Mir1 10000 1000 1 #> 3 3 7 Gene3 Mir1 5000 1000 1 #> # … with 4 more rows, and 12 more variables: afff_factor <dbl>, #> # degg_factor <dbl>, comp_count_list <list>, comp_count_pre <dbl>, #> # comp_count_current <dbl>, mirna_count_list <list>, mirna_count_pre <dbl>, #> # mirna_count_current <dbl>, mirna_count_per_dep <dbl>, effect_current <dbl>, #> # effect_pre <dbl>, effect_list <list>
priming_graph(minsamp, Competing_expression, miRNA_expression, aff_factor = c(seed_type,energy), deg_factor = region)%>% update_how('Gene1', 3)
#> Warning: First column is processed as competing and the second as miRNA.
#> # A tbl_graph: 8 nodes and 7 edges #> # #> # A rooted tree #> # #> # Node Data: 8 x 7 (active) #> name type node_id initial_count count_pre count_current changes_variable #> <chr> <chr> <int> <dbl> <dbl> <dbl> <chr> #> 1 Gene1 Competing 1 10000 10000 30000 Up #> 2 Gene2 Competing 2 10000 10000 10000 Competing #> 3 Gene3 Competing 3 5000 5000 5000 Competing #> 4 Gene4 Competing 4 10000 10000 10000 Competing #> 5 Gene5 Competing 5 5000 5000 5000 Competing #> 6 Gene6 Competing 6 10000 10000 10000 Competing #> # … with 2 more rows #> # #> # Edge Data: 7 x 22 #> from to Competing_name miRNA_name Competing_expre… miRNA_expression #> <int> <int> <chr> <chr> <dbl> <dbl> #> 1 1 7 Gene1 Mir1 10000 1000 #> 2 2 7 Gene2 Mir1 10000 1000 #> 3 3 7 Gene3 Mir1 5000 1000 #> # … with 4 more rows, and 16 more variables: seed_type <dbl>, energy <dbl>, #> # region <dbl>, dummy <dbl>, afff_factor <dbl>, degg_factor <dbl>, #> # comp_count_list <list>, comp_count_pre <dbl>, comp_count_current <dbl>, #> # mirna_count_list <list>, mirna_count_pre <dbl>, mirna_count_current <dbl>, #> # mirna_count_per_dep <dbl>, effect_current <dbl>, effect_pre <dbl>, #> # effect_list <list>
priming_graph(minsamp, Competing_expression, miRNA_expression, aff_factor = c(seed_type,energy), deg_factor = region)%>% update_how('Gene1', how=0, knockdown= TRUE)
#> Warning: First column is processed as competing and the second as miRNA.
#> # A tbl_graph: 8 nodes and 7 edges #> # #> # A rooted tree #> # #> # Node Data: 8 x 7 (active) #> name type node_id initial_count count_pre count_current changes_variable #> <chr> <chr> <int> <dbl> <dbl> <dbl> <chr> #> 1 Gene1 Competing 1 10000 0 0 Competing #> 2 Gene2 Competing 2 10000 10000 10000 Competing #> 3 Gene3 Competing 3 5000 5000 5000 Competing #> 4 Gene4 Competing 4 10000 10000 10000 Competing #> 5 Gene5 Competing 5 5000 5000 5000 Competing #> 6 Gene6 Competing 6 10000 10000 10000 Competing #> # … with 2 more rows #> # #> # Edge Data: 7 x 22 #> from to Competing_name miRNA_name Competing_expre… miRNA_expression #> <int> <int> <chr> <chr> <dbl> <dbl> #> 1 1 7 Gene1 Mir1 10000 1000 #> 2 2 7 Gene2 Mir1 10000 1000 #> 3 3 7 Gene3 Mir1 5000 1000 #> # … with 4 more rows, and 16 more variables: seed_type <dbl>, energy <dbl>, #> # region <dbl>, dummy <dbl>, afff_factor <dbl>, degg_factor <dbl>, #> # comp_count_list <list>, comp_count_pre <dbl>, comp_count_current <dbl>, #> # mirna_count_list <list>, mirna_count_pre <dbl>, mirna_count_current <dbl>, #> # mirna_count_per_dep <dbl>, effect_current <dbl>, effect_pre <dbl>, #> # effect_list <list>