Contents

1 Overview

The levi (Landscape Expression Visualization Interface) is a package for the R environment, developed to enable the visualization of the projection of gene expression on a biological network. levi is based on two other software, the first is the Viacomplex (Castro et al. (2009)), which was written in Fortran using the Dislin library to plot the data. The second is Galant (Camilo et al. (2013)), which corresponds to a plugin for Cytoscape software.

Two files are required to use levi: The file containing the expression levels of the genes and a file containing the biological network.

2 Files

2.1 Gene Expression Levels

This file should contain the genes of interest previously normalized by the user. The expression file (see Example) must have a column with the identification of genes (Gene Symbol, Entrez, etc.) and at least one column with gene expression levels (treatment, case, control, etc.). The user can compare the expression levels between samples if there are more columns containing these data.

If the expression file does not have values for all the genes of the network, a message will be displayed showing log file path to a temporary directory with the gene names. In the landscape construction, genes with no expression value will be displayed with values close to 0.5 demonstrating that there were no changes (down-regulated or up-regulated genes).

Data sets of gene expression can be obtained from online databases:

2.2 Biological Network

The levi supports several extensions of biological network files (*.net, *.dyn, *.txt, *.dat). The user should build the biological network using specific tools such as: Cytoscape, RedeR, Medusa, etc. To build the biological network is recommended the obtention of interaction data/ biological associations from online repositories:

Extension File Type Link
dat Medusa (DAT) Example DAT
dyn RedeR (DYN) Example DYN
net Pajek (NET) Example NET
stg STRING / STITCH Example coordinates
stg STRING / STITCH Example interactions

#Viewing Modes

levi has two viewing modes: Graphical User Interface (GUI) and script.

2.3 Graphical User Interface (GUI)

The GUI mode was developed using Shiny package (Figure 1). This viewing mode can be used in the R environment (browser=FALSE) or in the user’s default operating system browser (browser=TRUE).

library(levi)
LEVIui(browser=TRUE)  #Launch Levi to Browser.
LEVIui(browser=FALSE) #Launch Levi to R environment.
Figure 2: Graphical User Interface (GUI).
  • 1 - Tabs
    • File - General options for uploading the data files.
    • Settings - Options to build the landscape.
  • 2 - Network input type: - Selection of the biological network input format. The options are available on the table 1.
  • 3 - Upload the network file - Input button to select the biological network file.
  • 4 - Upload the expression file - Input button to select the gene expression levels file.
  • 5 - Expression values in log scale - select when there is low variation between expression data
  • 6 - Selected fields - Selecting the type of analysis. Comparison between two samples or a single sample.
  • 7 - Select gene symbol field - Selection of the gene ID contained in the gene expression levels file. The gene ID in the biological network file must be the same in the gene expression levels file. Select test field
  • Select the case/test sample. Select control field - Select the control sample. If levi detects the case/test sample and control sample as equal, then levi will apply the “single sample” analysis.
  • 8 - Chart Colors - Color palette to build the landscape. There is two options the Multicolor has 20 color levels combined. The Two colors has two categories of color palettes, multicolor and two colors. For the selection of two colors the available options are: purple_pink, green_blue, blue_yellow, pink_green, orange_purple, green_marine. Both of them is targeted to show the biological network with higher expression. (Figure 3 and Figure 4).
  • 9 - Chart with contour - Enable or disable the contour lines in the landscape.
  • 10 - landscape Image display area. The user can select specific areas of the image to inspect the gene name and position.
  • 11 - Expression area: - Total expression value of the selected area in the image.
  • 12 - Download options
    • File format to landscape - Select the output format of the landscape. The options available are: TIFF, BMP, JPEG and PNG. We recommend using this option in the browser.
    • Download Plot - Button to save the file.
  • 13 - Visualization of gene name and expression value of the selected area in the landscape. The user can save the table in a csv file (button Download Data)
  • 14 - Settings
    • Contrast - Constrast value in the landscape. The variable range is 1 to 100. The default value is 50.
    • Resolution - Image size of the landscape. The variable range is 1 to 100. The default value is 50. If this parameter is higher, then the total time required will be longer.
    • Smoothing - Smoothing of the landscape. The variable range is 1 to 100. The default value is 50.I f this parameter is higher, then the total time required will be longer.
    • Zoom - Zoom value for the landscape. The variable range is 1 to 100. The default value is 50.

2.4 Script

The levi scripting mode also has the settings for landscape building (see example below).

library(levi)

template_network <- file.path(system.file(package="levi"),"extdata",
                                "medusa.dat", fsep = .Platform$file.sep)

template_expression <- file.path(system.file(package="levi"),
                                "extdata","expression.dat", 
                                fsep = .Platform$file.sep)

multicolor <- levi(networkCoordinatesInput = template_network,
                expressionInput = template_expression, fileTypeInput = "dat",
                geneSymbolnput = "ID", 
                readExpColumn=
                readExpColumn("TumorCurrentSmoker-NormalNeverSmoker"), 
                contrastValueInput = 50, resolutionValueInput  = 50, 
                zoomValueInput = 50, smoothValueInput = 50, contourLevi = TRUE)
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.

twocolors <- levi(networkCoordinatesInput = template_network,
                expressionInput = template_expression, fileTypeInput = "dat",
                geneSymbolnput = "ID", 
                readExpColumn=
                readExpColumn("TumorCurrentSmoker-NormalNeverSmoker"),
                setcolor = "pink_green", contourLevi = FALSE)
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.

The script mode allows the user to compare combinations between two experiments in the gene expression levels file. The readExpColumn function can be used to this task to inform the combination separating by dash (-) and to add more combinations separate by comma (,).

library(levi)
base <- readExpColumn("TumorFormerSmoker-NormalFormerSmoker", 
                        "TumorNeverSmoker-TumorNeverSmoker")

template_network <- file.path(system.file(package="levi"),"extdata",
                                "medusa.dat", fsep = .Platform$file.sep)

template_expression <- file.path(system.file(package="levi"),
                                "extdata","expression.dat", 
                                fsep = .Platform$file.sep)

multicolor <- levi(networkCoordinatesInput = template_network,
                    expressionInput = template_expression, 
                    fileTypeInput = "dat",
                    geneSymbolnput = "ID", readExpColumn= base, 
                    contrastValueInput = 50, resolutionValueInput  = 50, 
                    zoomValueInput = 50, smoothValueInput = 50, 
                    contourLevi = FALSE)
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.

twocolors <- levi(networkCoordinatesInput = template_network,
                expressionInput = template_expression, fileTypeInput = "dat",
                geneSymbolnput = "ID", 
                readExpColumn= base,
                setcolor = "pink_green", contourLevi = FALSE)
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.
## Coordinate system already present. Adding new coordinate system, which will replace the existing one.

3 Session information

## R version 4.0.0 (2020-04-24)
## Platform: x86_64-pc-linux-gnu (64-bit)
## Running under: Ubuntu 18.04.4 LTS
## 
## Matrix products: default
## BLAS:   /home/biocbuild/bbs-3.11-bioc/R/lib/libRblas.so
## LAPACK: /home/biocbuild/bbs-3.11-bioc/R/lib/libRlapack.so
## 
## locale:
##  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
##  [3] LC_TIME=en_US.UTF-8        LC_COLLATE=C              
##  [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
##  [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
##  [9] LC_ADDRESS=C               LC_TELEPHONE=C            
## [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       
## 
## attached base packages:
## [1] stats     graphics  grDevices utils     datasets  methods   base     
## 
## other attached packages:
## [1] levi_1.6.0       BiocStyle_2.16.0
## 
## loaded via a namespace (and not attached):
##  [1] Rcpp_1.0.4.6         later_1.0.0          pillar_1.4.3        
##  [4] compiler_4.0.0       RColorBrewer_1.1-2   BiocManager_1.30.10 
##  [7] plyr_1.8.6           shinyjs_1.1          tools_4.0.0         
## [10] testthat_2.3.2       digest_0.6.25        evaluate_0.14       
## [13] lifecycle_0.2.0      tibble_3.0.1         gtable_0.3.0        
## [16] pkgconfig_2.0.3      rlang_0.4.5          igraph_1.2.5        
## [19] shiny_1.4.0.2        magick_2.3           yaml_2.2.1          
## [22] xfun_0.13            fastmap_1.0.1        xml2_1.3.2          
## [25] dplyr_0.8.5          stringr_1.4.0        httr_1.4.1          
## [28] knitr_1.28           htmlwidgets_1.5.1    vctrs_0.2.4         
## [31] isoband_0.2.1        DT_0.13              grid_4.0.0          
## [34] shinydashboard_0.7.1 tidyselect_1.0.0     glue_1.4.0          
## [37] R6_2.4.1             rmarkdown_2.1        bookdown_0.18       
## [40] farver_2.0.3         purrr_0.3.4          ggplot2_3.3.0       
## [43] reshape2_1.4.4       magrittr_1.5         promises_1.1.0      
## [46] scales_1.1.0         ellipsis_0.3.0       htmltools_0.4.0     
## [49] assertthat_0.2.1     xtable_1.8-4         mime_0.9            
## [52] colorspace_1.4-1     httpuv_1.5.2         labeling_0.3        
## [55] stringi_1.4.6        munsell_0.5.0        crayon_1.3.4

Reference

Camilo, Esther, Luiz A Bovolenta, Marcio L Acencio, Jose L Rybarczyk-Filho, Mauro AA Castro, Jose CF Moreira, and Ney Lemke. 2013. “GALANT: A Cytoscape Plugin for Visualizing Data as Functional Landscapes Projected onto Biological Networks.” Bioinformatics 29 (19). Oxford University Press:2505–6.

Castro, Mauro AA, José L Rybarczyk Filho, Rodrigo JS Dalmolin, Marialva Sinigaglia, José CF Moreira, José CM Mombach, and Rita MC de Almeida. 2009. “ViaComplex: Software for Landscape Analysis of Gene Expression Networks in Genomic Context.” Bioinformatics 25 (11). Oxford University Press:1468–9.