Loading...
 

Flux Balance Analysis Plug-In

Image
The Flux Balance Analysis Plug-In equips Omix with the capability to compute flux distributions on metabolic networks by using an optimization approach. Read more about flux balance analysis here. Internally, the Flux Balance Analysis Plug-In uses lpsolve for linear programming.

Using the Plug-In

Flux balance analysis requires a network stoichiometry and constraints. For defining constraints use the Network Constraints Plug-In. FBA only uses the net flux contraints and net flux general bounds. If no general bounds are given, FBA uses default bounds of -1000 to 1000.

After preparing the network model, you can start computation of flux balance analysis by pressing the menu entry "Extras -> Compute FBA":

FBA entry in the 'Extras' menu
FBA entry in the 'Extras' menu


Subsequently, you are requested to enter an objective function that shall be optimized in FBA. The objective function editor is a linear expression that follows the same syntactical rules as known from the network constraints editor. However, only linear expressions are valid.

Objective function dialog
Objective function dialog


For instance, you can enter a single reaction name or a summation of multiple reactions:
  • A
  • A+B
  • A-C
  • 2*A+3*D
By confirming the objective function dialog, the flux balance analysis is started.

1.1.1. Results

After successful computation, the result of the flux balance analysis are displayed in a tabular sidebar which usually appears immediately at the bottom of the main window. If this sidebar is initially invisible due to certain reason, you can activate it by selecting menu entry "View" -> "Sidebars" -> "FBA Results".

FBA result sidebar
FBA result sidebar


The "FBA Results" sidebar shows a table in which the individual analysis results are listed row by row. The first table column shows the objective function, the second column shows the computed objective value.
The following columns represent the reactions of the network filled with the flux rates in the FBA results. All displayed FBA results can be exported to CSV file by selecting the "Save As..." button.

1.1.2. Visualization

You can display the flux distribution in the FBA result by selecting a row and pressing the "Visualization..." button in the bottom right corner of the FBA results sidebar. Select the "Show Selected Result" entry from the drop-down menu. When first starting FBA visualization, you are requested to configure, how to visualize the results:

Configuring the FBA visualization
Configuring the FBA visualization


Following options are available:
  • "adapt edge width" - map a reactions flux rate to the width of all flux edges connected to the reaction
  • "adapt local pathway strength" - map a reactions flux rate to the local strength of the pathway, the reaction belongs to
  • "adapt inverted-state of reactions" - if a reactions flux rate is negative invert its displayed direction
  • "hide reactions whose flux value is zero"; likewise, all flux edges and metabolites are hidden that do not connect to a non-zero reaction


By selecting "visualize log-scaled values", all flux rates are log-scaled before displayed.
Alternatively, you can write own OVL code to visualize the FBA result which is activated by selecting "use custom visualization function" (see below).

1.1.3. Custom Visualization

In order to customize the way, FBA results are visualized in the network extend the definition of the Reaction type by a method called "visualizeFBAFluxValue(var,var)" realizing the visualization and optionally a reset method called "resetFBA()":

extend Reaction{
    function visualizeFBAFluxValue(var absoluteValue, var relativeValue){
		//...
    }

    function resetFBA(){
		//...
    }
}


The first parameter of function "visualizeFBAFluxValue(var,var)" is the absolute value of the flux in the flux distribution, the second parameter is the relative value in ranges between -1 and 1 (optionally log-scaled).
All changes to the visual appearance of the diagram that are done in "visualizeFBAFluxValue(var,var)" should be reset to the default values in "resetFBA()".

Instead of using JavaScript syntax, you can also use Java syntax:

void visualizeFBAFluxValue(double absoluteValue, double relativeValue){
	//...
}


More information about how to use OVL for data visualization can be found in the Omix User Manual.

The following example displays the absolute flux rates of a reaction as textual annotation and displays the relative value by the fill level size:

extend Reaction{

    DoubleField fluxValueField : void;

    function visualizeFBAFluxValue(var absoluteValue, var relativeValue){
		fluxValueField.value = absoluteValue;
		fillLevel = Math.abs(relativeValue);

		if(relativeValue>0){
			fillLevelIndication = FillLevelIndication.CLOCKWISE;
		}else{
			fillLevelIndication = FillLevelIndication.COUNTER_CLOCKWISE;
		}
    }

    function resetFBA(){
		fluxValueField.value = null;
		fillLevel = null;
		fillLevelIndication = null;
    }
}


1.2. Converting Old Models

Before version 1.4.0, the FBA plug-in used an own constraints definition mechanism instead of cooperating with the Network Constraints Plug-In. Currently, the FBA plug-in still supports loading and editing constraints in the old fashion. However, since this functionality will be removed in a future version, old models should be converted.

Therefore, select the menu entry "Extras" -> "Convert FBA Constraints". This activates the Network Constraints Plug-In, converts all old FBA constraints to network constraints and finally removes all FBA constraints properties from the network.