ssGSEA2.0 and PTM-SEA

repository·master·Indexed 43 days ago

https://github.com/broadinstitute/ssgsea2.0

A toolset for single-sample enrichment analysis supporting gene-centric ssGSEA for gene expression data and site-centric PTM-SEA for phosphoproteomics data using the PTMsigDB database. Available as a command-line tool (ssgsea-cli.R), an R package, a GenePattern module, and an R-GUI/RStudio interface. Supports GCT v1.2 and v1.3 input formats and GMT gene set databases.

Tokens
1.9K
Snippets
2
Records
15
Agent score
6%

What's inside ssGSEA2.0

  1. Overview of ssGSEA2.0 and PTM-SEA

    master

    ssGSEA2.0/PTM-SEA is a toolset for performing enrichment analysis on biological datasets. It supports two primary modes:

    1. ssGSEA (single sample Gene Set Enrichment Analysis): Used for gene-centric analysis of gene expression data (e.g., mRNAs, proteins). It typically uses gene sets from the Molecular Signatures Database (MSigDB) provided in .gmt format.
    2. PTM-SEA (PTM Signature Enrichment Analysis): A modified version of ssGSEA designed for site-centric phosphoproteomics data. It uses the PTM signatures database (PTMsigDB) to score bi-directional signature sets (e.g., kinase activities, signaling pathways, or disease-associated signatures).

    Note: This repository is a supplement to the original ssGSEA R implementation. The official codebase for ssGSEA can be found at GSEA-MSigDB/ssGSEA-gpmodule.

  2. Key features of the ssGSEA R-implementation

    master

    The current implementation of ssGSEA is an adaptation of the original code by Pablo Tamayo, featuring several enhancements for modern workflows:

    • Parallel Processing: Support for multiple CPU cores using the doParallel R package.
    • GCT v1.3 Support: Compatibility with GCT v1.3 format via the cmapR package.
    • Improved Robustness: Better handling of missing values and basic error handling.
    • PTM-SEA Support: Capability for scoring directional gene sets (specifically for PTMsigDB).
    • Performance & Output: Improved runtime performance and generation of additional diagnostic files, such as rank plots and parameter files.
  3. PTMsigDB Site Identifier Formats

    master

    To perform PTM-SEA, your dataset's site identifiers must match one of the three formats supported by PTMsigDB.

    Important: While PTMsigDB signatures include a directionality suffix (;u for up-regulation or ;d for down-regulation), you must not include this suffix when generating identifiers for your own dataset. The directionality is handled by the scoring scheme.

    FormatSite Accession PatternExample in PTMsigDBExample in your dataset
    UniProt-centricUniprot_acc;site-type;directionQ06609;Y315-p;uQ06609;Y315-p
    Flanking sequence+/-7aa flanking seq-type;directionETRICKIYDSPCLPE-p;uETRICKIYDSPCLPE-p
    PSP site group idsite_grp_id-type;direction448324-p;u448324-p

    Recommendation: It is generally recommended to use the Flanking sequence identifier, as it is more invariant to updates in protein sequence databases.

  4. Configure ssGSEA/PTM-SEA parameters

    master

    You can customize the parameters for ssGSEA or PTM-SEA analysis in two ways:

    1. Via R Script: Modify the parameters section within the ssgsea-gui.R file.
    2. Via Command Line: Pass parameters as arguments when running the tool from the command line.

    Note that the default parameters are pre-configured to provide reliable results for most standard use cases.

  5. Understand PTM site identifiers in PTMsigDB

    master

    To ensure compatibility across different proteomics software and protein databases, PTMsigDB represents phosphorylation sites using three identifier types.

    Important: When generating site identifiers for your own dataset, do not include the directionality (;u or ;d) which is a feature of the PTMsigDB database itself.

    Database formatSite accession patternExample in PTMsigDBExample in dataset
    UniProt-centricUniprot_acc;site-type;directionQ06609;Y315-p;uQ06609;Y315-p
    Flanking sequence+/-7aa flanking seq-type;directionETRICKIYDSPCLPE-p;uETRICKIYDSPCLPE-p
    PSP site group idsite_grp_id-type;direction448324-p;u448324-p

    Recommendation: It is generally recommended to use the Flanking sequence as the site identifier, as these are more invariant to updates in protein sequence databases.

  6. How to use ssGSEA 2.0 and PTM-SEA tools

    master

    The ssGSEA 2.0 and PTM-SEA toolsets can be utilized through several different interfaces depending on your workflow requirements:

    • GenePattern: For users integrated into the GenePattern ecosystem.
    • R-GUI / RStudio: For interactive analysis within an R environment.
    • R Package: For programmatic integration into R-based bioinformatics pipelines.
    • Command Line: For automated, high-throughput, or headless execution.

    Before running these tools, ensure your input data is correctly formatted (see 'Preprocessing input GCT' for details).

  7. Use ssGSEA2.0 as an R Package

    master
    An R package incorporating ssGSEA2.0 is available for programmatic use within R environments. It supports both R 3.6 and R >= 4.0 and includes all necessary dependencies. Detailed instructions for installation and usage can be found on the package's GitHub repository: https://github.com/nicolerg/ssGSEA2.0.
  8. Run ssGSEA2.0/PTM-SEA via R-GUI or RStudio

    master

    The ssgsea-gui.R script provides a user-friendly interface that requires little to no R or command line knowledge. It uses Windows-style file dialogs to select inputs.

    Usage

    • RStudio: Open the file and click 'Source' in the upper right of the editor.
    • R-GUI: Drag and drop the file into an R-GUI window.
    • macOS/iOS: Requires XQuartz to be installed to enable file dialogs.

    Workflow

    1. The script prompts for a folder containing input files in GCT v1.2 or GCT v1.3 format.
    2. The script loops over all GCT files in that directory and runs ssGSEA on each.
    3. A second dialog allows you to select one or multiple gene set databases in GMT format (e.g., MSigDB).