as.reactions: Converts a stochiometric matrix to a reaction list.

Description Usage Arguments Value Examples

Description

Converts a stochiometric matrix to a reaction list.

Usage

1
as.reactions(s_matrix, reversible = FALSE, r_names = NA)

Arguments

s_matrix

The stochiometric matrix to be converted.

reversible

Marks reversible reactions. FALSE denotes that all reactions are irreversible. Otherwise a boolean vector of length n_r defining the reversibility for each reaction.

r_names

If NA reaction names are generated as r1,...,rn. Can be a vector of length n_r denoting names for the reactions.

Value

A reaction list containing the reactions from S.

Examples

1
2
3
S <- matrix(c(-1,1,1,-1), nrow=2)
rownames(S) <- c('A', 'B')
print(as.reactions(S))

cdiener/dycone documentation built on May 13, 2019, 2:41 p.m.