├── .github └── workflows │ └── publish_to_pypi.yml ├── .gitignore ├── .readthedocs.yaml ├── LICENSE ├── README.rst ├── docs ├── Makefile ├── make.bat ├── requirements.txt └── source │ ├── api.rst │ ├── conf.py │ ├── examples.rst │ ├── index.rst │ ├── installation.rst │ └── quickstart.rst ├── example.ipynb ├── example_data ├── tcga.tsv ├── test1.tsv └── test2.tsv ├── oncoprint.png ├── pyoncoprint └── __init__.py ├── pyproject.toml ├── requirements.txt └── uv.lock /.github/workflows/publish_to_pypi.yml: -------------------------------------------------------------------------------- 1 | # This workflow will upload a Python Package using Twine when a release is created 2 | # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries 3 | 4 | # This workflow uses actions that are not certified by GitHub. 5 | # They are provided by a third-party and are governed by 6 | # separate terms of service, privacy policy, and support 7 | # documentation. 8 | 9 | name: Publish Python Package 10 | 11 | on: 12 | release: 13 | types: [published] 14 | workflow_dispatch: 15 | push: 16 | tags: 17 | - v** 18 | permissions: 19 | contents: read 20 | id-token: write 21 | jobs: 22 | deploy: 23 | runs-on: ubuntu-latest 24 | steps: 25 | - uses: actions/checkout@v4 26 | - name: Set up Python 27 | uses: actions/setup-python@v3 28 | with: 29 | python-version: '3.x' 30 | - name: Install dependencies 31 | run: | 32 | python -m pip install --upgrade pip 33 | pip install build 34 | - name: Build package 35 | run: python -m build 36 | - name: Publish package 37 | uses: pypa/gh-action-pypi-publish@release/v1 38 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *.py[cod] 4 | *$py.class 5 | 6 | # C extensions 7 | *.so 8 | 9 | # Distribution / packaging 10 | .Python 11 | build/ 12 | develop-eggs/ 13 | dist/ 14 | downloads/ 15 | eggs/ 16 | .eggs/ 17 | lib/ 18 | lib64/ 19 | parts/ 20 | sdist/ 21 | var/ 22 | wheels/ 23 | pip-wheel-metadata/ 24 | share/python-wheels/ 25 | *.egg-info/ 26 | .installed.cfg 27 | *.egg 28 | MANIFEST 29 | 30 | # PyInstaller 31 | # Usually these files are written by a python script from a template 32 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 33 | *.manifest 34 | *.spec 35 | 36 | # Installer logs 37 | pip-log.txt 38 | pip-delete-this-directory.txt 39 | 40 | # Unit test / coverage reports 41 | htmlcov/ 42 | .tox/ 43 | .nox/ 44 | .coverage 45 | .coverage.* 46 | .cache 47 | nosetests.xml 48 | coverage.xml 49 | *.cover 50 | *.py,cover 51 | .hypothesis/ 52 | .pytest_cache/ 53 | 54 | # Translations 55 | *.mo 56 | *.pot 57 | 58 | # Django stuff: 59 | *.log 60 | local_settings.py 61 | db.sqlite3 62 | db.sqlite3-journal 63 | 64 | # Flask stuff: 65 | instance/ 66 | .webassets-cache 67 | 68 | # Scrapy stuff: 69 | .scrapy 70 | 71 | # Sphinx documentation 72 | docs/_build/ 73 | 74 | # PyBuilder 75 | target/ 76 | 77 | # Jupyter Notebook 78 | .ipynb_checkpoints 79 | 80 | # IPython 81 | profile_default/ 82 | ipython_config.py 83 | 84 | # pyenv 85 | .python-version 86 | 87 | # pipenv 88 | # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. 89 | # However, in case of collaboration, if having platform-specific dependencies or dependencies 90 | # having no cross-platform support, pipenv may install dependencies that don't work, or not 91 | # install all needed dependencies. 92 | #Pipfile.lock 93 | 94 | # PEP 582; used by e.g. github.com/David-OConnor/pyflow 95 | __pypackages__/ 96 | 97 | # Celery stuff 98 | celerybeat-schedule 99 | celerybeat.pid 100 | 101 | # SageMath parsed files 102 | *.sage.py 103 | 104 | # Environments 105 | .env 106 | .venv 107 | env/ 108 | venv/ 109 | ENV/ 110 | env.bak/ 111 | venv.bak/ 112 | 113 | # Spyder project settings 114 | .spyderproject 115 | .spyproject 116 | 117 | # Rope project settings 118 | .ropeproject 119 | 120 | # mkdocs documentation 121 | /site 122 | 123 | # mypy 124 | .mypy_cache/ 125 | .dmypy.json 126 | dmypy.json 127 | 128 | # Pyre type checker 129 | .pyre/ 130 | -------------------------------------------------------------------------------- /.readthedocs.yaml: -------------------------------------------------------------------------------- 1 | # Read the Docs configuration file 2 | # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details 3 | 4 | # Required 5 | version: 2 6 | 7 | # Set the version of Python and other tools you might need 8 | build: 9 | os: ubuntu-22.04 10 | tools: 11 | python: "3.11" 12 | 13 | # Build documentation in the docs/ directory with Sphinx 14 | sphinx: 15 | configuration: docs/source/conf.py 16 | 17 | # Optionally declare the Python requirements required to build your docs 18 | python: 19 | install: 20 | - requirements: requirements.txt 21 | - method: pip 22 | path: . 23 | - requirements: docs/requirements.txt -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | BSD 2-Clause License 2 | 3 | Copyright (c) 2020, Jeongbin Park 4 | All rights reserved. 5 | 6 | Redistribution and use in source and binary forms, with or without 7 | modification, are permitted provided that the following conditions are met: 8 | 9 | 1. Redistributions of source code must retain the above copyright notice, this 10 | list of conditions and the following disclaimer. 11 | 12 | 2. Redistributions in binary form must reproduce the above copyright notice, 13 | this list of conditions and the following disclaimer in the documentation 14 | and/or other materials provided with the distribution. 15 | 16 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 17 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 18 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 19 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 20 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 22 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 23 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 24 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 25 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | PyOncoPrint 2 | =========== 3 | 4 | |downloads| |downloads/month| |downloads/week| 5 | 6 | Draw OncoPrint using Python. Check out `example.ipynb `_ for basic usage. 7 | 8 | Please cite as: 9 | 10 | - Jeongbin Park and Nagarajan Paramasivam, "PyOncoPrint: a python package for plotting OncoPrints", *Genomics & Informatics* 21(1): e14 (2023), `doi:10.5808/gi.22079 `_ 11 | 12 | An example output: 13 | 14 | .. image:: oncoprint.png 15 | :alt: Example oncoprint image 16 | 17 | Install 18 | ======= 19 | .. code-block:: bash 20 | 21 | $ pip install pyoncoprint 22 | 23 | Requirements 24 | ============ 25 | - matplotlib 26 | - numpy 27 | - pandas (to parse pandas dataframe) 28 | 29 | License 30 | ======= 31 | BSD 2-Clause License 32 | 33 | Copyright (c) 2020, Jeongbin Park 34 | All rights reserved. 35 | 36 | Redistribution and use in source and binary forms, with or without 37 | modification, are permitted provided that the following conditions are met: 38 | 39 | 1. Redistributions of source code must retain the above copyright notice, this 40 | list of conditions and the following disclaimer. 41 | 42 | 2. Redistributions in binary form must reproduce the above copyright notice, 43 | this list of conditions and the following disclaimer in the documentation 44 | and/or other materials provided with the distribution. 45 | 46 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 47 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 48 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 49 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 50 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 51 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 52 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 53 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 54 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 55 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 56 | 57 | .. |downloads| image:: https://static.pepy.tech/badge/pyoncoprint 58 | :alt: downloads 59 | :target: https://pepy.tech/project/pyoncoprint 60 | 61 | .. |downloads/month| image:: https://static.pepy.tech/badge/pyoncoprint/month 62 | :alt: downloads/month 63 | :target: https://pepy.tech/project/pyoncoprint 64 | 65 | .. |downloads/week| image:: https://static.pepy.tech/badge/pyoncoprint/week 66 | :alt: downloads/week 67 | :target: https://pepy.tech/project/pyoncoprint 68 | -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- 1 | # Minimal makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line, and also 5 | # from the environment for the first two. 6 | SPHINXOPTS ?= 7 | SPHINXBUILD ?= sphinx-build 8 | SOURCEDIR = source 9 | BUILDDIR = build 10 | 11 | # Put it first so that "make" without argument is like "make help". 12 | help: 13 | @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 14 | 15 | .PHONY: help Makefile 16 | 17 | # Catch-all target: route all unknown targets to Sphinx using the new 18 | # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). 19 | %: Makefile 20 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 21 | -------------------------------------------------------------------------------- /docs/make.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | pushd %~dp0 4 | 5 | REM Command file for Sphinx documentation 6 | 7 | if "%SPHINXBUILD%" == "" ( 8 | set SPHINXBUILD=sphinx-build 9 | ) 10 | set SOURCEDIR=source 11 | set BUILDDIR=build 12 | 13 | if "%1" == "" goto help 14 | 15 | %SPHINXBUILD% >NUL 2>NUL 16 | if errorlevel 9009 ( 17 | echo. 18 | echo.The 'sphinx-build' command was not found. Make sure you have Sphinx 19 | echo.installed, then set the SPHINXBUILD environment variable to point 20 | echo.to the full path of the 'sphinx-build' executable. Alternatively you 21 | echo.may add the Sphinx directory to PATH. 22 | echo. 23 | echo.If you don't have Sphinx installed, grab it from 24 | echo.https://www.sphinx-doc.org/ 25 | exit /b 1 26 | ) 27 | 28 | %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 29 | goto end 30 | 31 | :help 32 | %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% 33 | 34 | :end 35 | popd -------------------------------------------------------------------------------- /docs/requirements.txt: -------------------------------------------------------------------------------- 1 | sphinx>=8.0 2 | sphinx-rtd-theme>=3.0 3 | sphinxcontrib-napoleon>=0.7 -------------------------------------------------------------------------------- /docs/source/api.rst: -------------------------------------------------------------------------------- 1 | API Reference 2 | ============= 3 | 4 | .. currentmodule:: pyoncoprint 5 | 6 | OncoPrint Class 7 | --------------- 8 | 9 | .. autoclass:: OncoPrint 10 | :members: 11 | :undoc-members: 12 | :show-inheritance: 13 | 14 | .. automethod:: __init__ 15 | .. automethod:: oncoprint 16 | 17 | Parameters 18 | ---------- 19 | 20 | OncoPrint.__init__ 21 | ~~~~~~~~~~~~~~~~~~ 22 | 23 | .. list-table:: 24 | :widths: 20 20 60 25 | :header-rows: 1 26 | 27 | * - Parameter 28 | - Type 29 | - Description 30 | * - recurrence_matrix 31 | - pd.DataFrame or np.ndarray 32 | - Matrix of mutations/alterations (genes x samples). If DataFrame, genes should be index and samples should be columns 33 | * - genes 34 | - array-like, optional 35 | - Gene names for rows. If not provided, extracted from DataFrame index or auto-generated 36 | * - samples 37 | - array-like, optional 38 | - Sample names for columns. If not provided, extracted from DataFrame columns or auto-generated 39 | * - separator 40 | - str, default="," 41 | - Separator for multiple mutations in same cell 42 | 43 | OncoPrint.oncoprint 44 | ~~~~~~~~~~~~~~~~~~~ 45 | 46 | .. list-table:: 47 | :widths: 20 20 60 48 | :header-rows: 1 49 | 50 | * - Parameter 51 | - Type 52 | - Description 53 | * - markers 54 | - dict 55 | - Dictionary mapping mutation types to marker styles 56 | * - annotations 57 | - dict, optional 58 | - Clinical annotations to display 59 | * - heatmaps 60 | - dict, optional 61 | - Continuous data heatmaps 62 | * - title 63 | - str, default="" 64 | - Plot title 65 | * - gene_sort_method 66 | - str, default='default' 67 | - Method for sorting genes ('default', 'unsorted') 68 | * - sample_sort_method 69 | - str, default='default' 70 | - Method for sorting samples ('default', 'unsorted') 71 | * - figsize 72 | - list, default=[50, 20] 73 | - Figure size [width, height] 74 | * - topplot 75 | - bool, default=True 76 | - Show sample mutation frequency plot 77 | * - rightplot 78 | - bool, default=True 79 | - Show gene alteration frequency plot 80 | * - legend 81 | - bool, default=True 82 | - Show legend 83 | * - cell_background 84 | - str, default="#dddddd" 85 | - Background color for empty cells 86 | * - gap 87 | - float or list, default=0.3 88 | - Gap between cells (ratio) 89 | * - ratio_template 90 | - str, default="{0:.0%}" 91 | - Format string for gene frequency labels 92 | 93 | Marker Specifications 94 | --------------------- 95 | 96 | Markers define how different mutation types are displayed. Each marker must have a 'color' field. 97 | 98 | Rectangle/Fill Markers 99 | ~~~~~~~~~~~~~~~~~~~~~~ 100 | 101 | For rectangular patches that fill the cell: 102 | 103 | .. code-block:: python 104 | 105 | { 106 | 'marker': 'fill', # or 'rect' 107 | 'color': 'red', # Required 108 | 'width': 1.0, # Optional, 0-1 ratio (default: 1.0) 109 | 'height': 0.5, # Optional, 0-1 ratio (default: 1.0) 110 | 'zindex': 1, # Optional, z-order for layering (default: 1) 111 | 'linewidth': 0 # Optional, border width (default: 0) 112 | } 113 | 114 | Custom Patch Markers 115 | ~~~~~~~~~~~~~~~~~~~~ 116 | 117 | For custom shapes using matplotlib patches: 118 | 119 | .. code-block:: python 120 | 121 | from matplotlib.patches import Polygon 122 | 123 | { 124 | 'marker': Polygon([[0, 0], [1, 1], [1, 0]]), # Triangle 125 | 'color': 'green', # Required 126 | 'width': 1.0, # Optional, scaling factor 127 | 'height': 1.0, # Optional, scaling factor 128 | 'linewidth': 0, # Optional 129 | 'zindex': 1 # Optional 130 | } 131 | 132 | Scatter Markers 133 | ~~~~~~~~~~~~~~~ 134 | 135 | For point markers using matplotlib scatter: 136 | 137 | .. code-block:: python 138 | 139 | { 140 | 'marker': '*', # Any matplotlib marker symbol 141 | 'color': 'purple', # Required 142 | 's': 100, # Optional, marker size 143 | 'lw': 0, # Optional, edge line width 144 | 'zindex': 2 # Optional 145 | } 146 | 147 | Note: The 'zindex' parameter controls layering - lower values are drawn first (background), higher values on top. 148 | 149 | Annotation Specifications 150 | ------------------------- 151 | 152 | Categorical Annotations 153 | ~~~~~~~~~~~~~~~~~~~~~~~ 154 | 155 | .. code-block:: python 156 | 157 | { 158 | 'annotations': pd.DataFrame(...), # Categorical data 159 | 'colors': { 160 | 'Category1': 'color1', 161 | 'Category2': 'color2' 162 | }, 163 | 'order': 0 # Display order 164 | } 165 | 166 | Numerical Annotations 167 | ~~~~~~~~~~~~~~~~~~~~~ 168 | 169 | .. code-block:: python 170 | 171 | { 172 | 'annotations': pd.DataFrame(...), # Numerical data 173 | 'color': 'orange', # Single color for gradient 174 | 'order': 1 175 | } 176 | 177 | Heatmap Specifications 178 | ---------------------- 179 | 180 | .. code-block:: python 181 | 182 | { 183 | 'heatmap': pd.DataFrame(...), # Expression/continuous data 184 | 'cmap': 'RdBu_r', # Colormap name or object 185 | 'vmin': -3, # Optional, minimum value 186 | 'vmax': 3 # Optional, maximum value 187 | } 188 | 189 | Return Values 190 | ------------- 191 | 192 | The `oncoprint()` method returns: 193 | 194 | .. code-block:: python 195 | 196 | fig, (ax, ax2, ax_top, ax_annot, ax_right, ax_legend) 197 | 198 | Where: 199 | - ``fig``: matplotlib Figure object 200 | - ``ax``: Main oncoprint axis 201 | - ``ax2``: Twin axis for gene labels (right side) 202 | - ``ax_top``: Top barplot axis (sample frequencies), None if topplot=False 203 | - ``ax_annot``: Annotation tracks axis, None if no annotations 204 | - ``ax_right``: Right barplot axis (gene frequencies), None if rightplot=False 205 | - ``ax_legend``: Legend axis, None if legend=False 206 | 207 | Deprecated Parameters 208 | --------------------- 209 | 210 | The following parameters are deprecated but still supported for backward compatibility: 211 | 212 | - ``is_topplot``: Use ``topplot`` instead 213 | - ``is_rightplot``: Use ``rightplot`` instead 214 | - ``is_legend``: Use ``legend`` instead 215 | 216 | These will print a warning message if used. -------------------------------------------------------------------------------- /docs/source/conf.py: -------------------------------------------------------------------------------- 1 | # Configuration file for the Sphinx documentation builder. 2 | # 3 | # For the full list of built-in configuration values, see the documentation: 4 | # https://www.sphinx-doc.org/en/master/usage/configuration.html 5 | 6 | import os 7 | import sys 8 | sys.path.insert(0, os.path.abspath('../..')) 9 | 10 | # -- Project information ----------------------------------------------------- 11 | # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information 12 | 13 | project = 'PyOncoPrint' 14 | copyright = '2025, Jeongbin Park' 15 | author = 'Jeongbin Park' 16 | release = '0.2.6' 17 | version = '0.2.6' 18 | 19 | # -- General configuration --------------------------------------------------- 20 | # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration 21 | 22 | extensions = [ 23 | 'sphinx.ext.autodoc', 24 | 'sphinx.ext.viewcode', 25 | 'sphinx.ext.napoleon', 26 | 'sphinx.ext.intersphinx', 27 | ] 28 | 29 | templates_path = ['_templates'] 30 | exclude_patterns = [] 31 | 32 | language = 'en' 33 | 34 | # -- Options for HTML output ------------------------------------------------- 35 | # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output 36 | 37 | html_theme = 'sphinx_rtd_theme' 38 | html_static_path = ['_static'] 39 | 40 | # -- Extension configuration ------------------------------------------------- 41 | 42 | # Napoleon settings 43 | napoleon_google_docstring = True 44 | napoleon_numpy_docstring = True 45 | napoleon_include_init_with_doc = True 46 | napoleon_include_private_with_doc = False 47 | napoleon_include_special_with_doc = True 48 | napoleon_use_admonition_for_examples = False 49 | napoleon_use_admonition_for_notes = False 50 | napoleon_use_admonition_for_references = False 51 | napoleon_use_ivar = False 52 | napoleon_use_param = True 53 | napoleon_use_rtype = True 54 | napoleon_preprocess_types = False 55 | napoleon_type_aliases = None 56 | napoleon_attr_annotations = True 57 | 58 | # Intersphinx configuration 59 | intersphinx_mapping = { 60 | 'python': ('https://docs.python.org/3', None), 61 | 'numpy': ('https://numpy.org/doc/stable/', None), 62 | 'pandas': ('https://pandas.pydata.org/docs/', None), 63 | 'matplotlib': ('https://matplotlib.org/stable/', None), 64 | } 65 | 66 | # Autodoc settings 67 | autodoc_default_options = { 68 | 'members': True, 69 | 'member-order': 'bysource', 70 | 'special-members': '__init__', 71 | 'undoc-members': True, 72 | 'exclude-members': '__weakref__' 73 | } 74 | -------------------------------------------------------------------------------- /docs/source/examples.rst: -------------------------------------------------------------------------------- 1 | Examples 2 | ======== 3 | 4 | Example Data 5 | ------------ 6 | 7 | The following example datasets are available for download and testing: 8 | 9 | * `TCGA Lung Adenocarcinoma Data `_ - Real cancer genomics data from TCGA 10 | * `Test Dataset 1 `_ - Sample mutation data for testing 11 | * `Test Dataset 2 `_ - Additional test data 12 | * `Example Notebook `_ - Complete tutorial notebook 13 | 14 | Download these files to follow along with the examples below. 15 | 16 | Basic OncoPrint 17 | --------------- 18 | 19 | Creating a simple OncoPrint with common mutation types: 20 | 21 | .. code-block:: python 22 | 23 | import pyoncoprint 24 | import pandas as pd 25 | import matplotlib.pyplot as plt 26 | 27 | # Sample mutation data 28 | data = pd.DataFrame({ 29 | 'TCGA-01': ['Missense', '', 'Amplification', '', 'Missense'], 30 | 'TCGA-02': ['Truncating', 'Missense', '', '', ''], 31 | 'TCGA-03': ['', 'Amplification', 'Deep Deletion', 'Missense', ''], 32 | 'TCGA-04': ['Missense', '', '', 'Truncating', 'Amplification'], 33 | 'TCGA-05': ['', 'Missense', 'Amplification', '', 'Truncating'] 34 | }, index=['TP53', 'EGFR', 'PTEN', 'KRAS', 'PIK3CA']) 35 | 36 | # Define visual markers 37 | markers = { 38 | 'Missense': {'marker': 'fill', 'color': 'forestgreen', 'height': 0.5}, 39 | 'Truncating': {'marker': 'fill', 'color': 'black', 'height': 0.5}, 40 | 'Amplification': {'marker': 'fill', 'color': 'firebrick'}, 41 | 'Deep Deletion': {'marker': 'fill', 'color': 'royalblue'} 42 | } 43 | 44 | # Create OncoPrint 45 | op = pyoncoprint.OncoPrint(data) 46 | fig, axes = op.oncoprint(markers, figsize=[15, 8], title="Cancer Gene Mutations") 47 | plt.show() 48 | 49 | Multiple Mutations per Cell 50 | ---------------------------- 51 | 52 | PyOncoPrint supports multiple mutations in the same cell by separating them with commas: 53 | 54 | .. code-block:: python 55 | 56 | import pyoncoprint 57 | import pandas as pd 58 | 59 | # Data with multiple mutations per cell 60 | data = pd.DataFrame({ 61 | 'Sample1': ['Missense,Amplification', '', 'Truncating'], 62 | 'Sample2': ['Missense', 'Deep Deletion', ''], 63 | 'Sample3': ['', 'Missense,Splice', 'Amplification'] 64 | }, index=['TP53', 'EGFR', 'PTEN']) 65 | 66 | # Define markers - zindex controls layering 67 | markers = { 68 | 'Amplification': {'marker': 'fill', 'color': 'red', 'zindex': 0}, 69 | 'Deep Deletion': {'marker': 'fill', 'color': 'blue', 'zindex': 0}, 70 | 'Missense': {'marker': 'fill', 'color': 'green', 'height': 0.5, 'zindex': 1}, 71 | 'Truncating': {'marker': 'fill', 'color': 'black', 'height': 0.5, 'zindex': 1}, 72 | 'Splice': {'marker': 'fill', 'color': 'orange', 'height': 0.5, 'zindex': 1} 73 | } 74 | 75 | op = pyoncoprint.OncoPrint(data) 76 | fig, axes = op.oncoprint(markers, figsize=[12, 8]) 77 | 78 | TCGA-style OncoPrint 79 | -------------------- 80 | 81 | Recreating a TCGA-style visualization with multiple data types: 82 | 83 | .. code-block:: python 84 | 85 | import numpy as np 86 | from matplotlib.patches import Polygon 87 | 88 | # More complex mutation data 89 | mutation_data = pd.DataFrame({ 90 | 'Sample_' + str(i): np.random.choice( 91 | ['', 'Missense', 'Truncating', 'Splice', 'Inframe'], 92 | size=10, 93 | p=[0.5, 0.2, 0.1, 0.1, 0.1] 94 | ) for i in range(20) 95 | }, index=['Gene_' + str(i) for i in range(10)]) 96 | 97 | # CNA data (overlapping with mutations) 98 | for sample in mutation_data.columns[:10]: 99 | for gene in ['Gene_0', 'Gene_2', 'Gene_5']: 100 | if np.random.random() < 0.3: 101 | current = mutation_data.loc[gene, sample] 102 | if current: 103 | mutation_data.loc[gene, sample] = current + ',Amplification' 104 | else: 105 | mutation_data.loc[gene, sample] = 'Amplification' 106 | 107 | # TCGA-style markers 108 | markers = { 109 | 'Amplification': { 110 | 'marker': 'fill', 111 | 'color': 'red', 112 | 'zindex': 0 113 | }, 114 | 'Deep Deletion': { 115 | 'marker': 'fill', 116 | 'color': 'blue', 117 | 'zindex': 0 118 | }, 119 | 'Missense': { 120 | 'marker': Polygon([[0, 0], [1, 1], [1, 0]]), 121 | 'color': 'green', 122 | 'linewidth': 0, 123 | 'zindex': 1 124 | }, 125 | 'Truncating': { 126 | 'marker': 'fill', 127 | 'color': 'black', 128 | 'height': 0.5, 129 | 'zindex': 1 130 | }, 131 | 'Splice': { 132 | 'marker': 'fill', 133 | 'color': 'darkorange', 134 | 'height': 0.5, 135 | 'zindex': 1 136 | }, 137 | 'Inframe': { 138 | 'marker': 'fill', 139 | 'color': 'brown', 140 | 'height': 0.5, 141 | 'zindex': 1 142 | } 143 | } 144 | 145 | op = pyoncoprint.OncoPrint(mutation_data) 146 | fig, axes = op.oncoprint( 147 | markers, 148 | figsize=[25, 12], 149 | title="TCGA-style OncoPrint", 150 | gap=[0.3, 0.1] 151 | ) 152 | plt.show() 153 | 154 | Multi-track Visualization 155 | ------------------------- 156 | 157 | Combining mutations with clinical data and expression: 158 | 159 | .. code-block:: python 160 | 161 | # Mutation data 162 | mutations = pd.DataFrame({ 163 | f'Patient_{i}': np.random.choice( 164 | ['', 'Missense', 'Truncating'], 165 | size=8, 166 | p=[0.6, 0.3, 0.1] 167 | ) for i in range(30) 168 | }, index=['BRAF', 'NRAS', 'NF1', 'CDKN2A', 'TP53', 'PTEN', 'ARID2', 'KIT']) 169 | 170 | # Clinical annotations 171 | stage = pd.DataFrame( 172 | np.random.choice(['I', 'II', 'III', 'IV'], size=30), 173 | columns=mutations.columns, 174 | index=['Stage'] 175 | ) 176 | 177 | mutation_count = pd.DataFrame( 178 | np.random.poisson(50, size=30), 179 | columns=mutations.columns, 180 | index=['TMB'] 181 | ) 182 | 183 | # Expression heatmap 184 | expression = pd.DataFrame( 185 | np.random.randn(8, 30), 186 | index=mutations.index, 187 | columns=mutations.columns 188 | ) 189 | 190 | # Methylation heatmap 191 | methylation = pd.DataFrame( 192 | np.random.beta(2, 5, size=(8, 30)), 193 | index=mutations.index, 194 | columns=mutations.columns 195 | ) 196 | 197 | # Configure visualizations 198 | markers = { 199 | 'Missense': {'marker': 'fill', 'color': 'green', 'height': 0.5}, 200 | 'Truncating': {'marker': 'fill', 'color': 'black', 'height': 0.5} 201 | } 202 | 203 | annotations = { 204 | 'Cancer Stage': { 205 | 'annotations': stage, 206 | 'colors': { 207 | 'I': 'lightgreen', 208 | 'II': 'yellow', 209 | 'III': 'orange', 210 | 'IV': 'red' 211 | }, 212 | 'order': 0 213 | }, 214 | 'Tumor Mutation Burden': { 215 | 'annotations': mutation_count, 216 | 'color': 'purple', 217 | 'order': 1 218 | } 219 | } 220 | 221 | heatmaps = { 222 | 'Expression (Z-score)': { 223 | 'heatmap': expression, 224 | 'cmap': 'RdBu_r', 225 | 'vmin': -3, 226 | 'vmax': 3 227 | }, 228 | 'Methylation (Beta)': { 229 | 'heatmap': methylation, 230 | 'cmap': 'Blues', 231 | 'vmin': 0, 232 | 'vmax': 1 233 | } 234 | } 235 | 236 | # Create comprehensive OncoPrint 237 | op = pyoncoprint.OncoPrint(mutations) 238 | fig, axes = op.oncoprint( 239 | markers, 240 | annotations=annotations, 241 | heatmaps=heatmaps, 242 | figsize=[40, 20], 243 | title="Multi-track Cancer Genomics Visualization" 244 | ) 245 | plt.tight_layout() 246 | plt.show() 247 | 248 | Custom Sorting 249 | -------------- 250 | 251 | Controlling gene and sample ordering: 252 | 253 | .. code-block:: python 254 | 255 | # Create data with specific patterns 256 | data = pd.DataFrame({ 257 | 'S1': ['Missense', 'Missense', '', ''], 258 | 'S2': ['Missense', '', 'Truncating', ''], 259 | 'S3': ['', '', 'Truncating', 'Missense'], 260 | 'S4': ['', 'Missense', '', 'Missense'], 261 | 'S5': ['Missense', 'Missense', 'Truncating', 'Missense'] 262 | }, index=['Gene_A', 'Gene_B', 'Gene_C', 'Gene_D']) 263 | 264 | markers = { 265 | 'Missense': {'marker': 'fill', 'color': 'green'}, 266 | 'Truncating': {'marker': 'fill', 'color': 'black'} 267 | } 268 | 269 | op = pyoncoprint.OncoPrint(data) 270 | 271 | # Default sorting (by frequency) 272 | fig1, _ = op.oncoprint( 273 | markers, 274 | figsize=[10, 6], 275 | title="Default Sorting", 276 | gene_sort_method='default', 277 | sample_sort_method='default' 278 | ) 279 | 280 | # No sorting (original order) 281 | fig2, _ = op.oncoprint( 282 | markers, 283 | figsize=[10, 6], 284 | title="Original Order", 285 | gene_sort_method='unsorted', 286 | sample_sort_method='unsorted' 287 | ) 288 | 289 | plt.show() 290 | 291 | Publication-ready Figure 292 | ------------------------ 293 | 294 | Creating a high-quality figure for publication: 295 | 296 | .. code-block:: python 297 | 298 | # Load your actual data here 299 | data = pd.DataFrame({ 300 | 'P1': ['Missense', '', 'Amplification', ''], 301 | 'P2': ['', 'Truncating', '', 'Missense'], 302 | 'P3': ['Missense', 'Missense', 'Deep Deletion', ''], 303 | 'P4': ['Amplification', '', '', 'Truncating'], 304 | 'P5': ['', 'Missense', 'Amplification', ''], 305 | 'P6': ['Truncating', '', '', 'Missense'], 306 | 'P7': ['', '', 'Deep Deletion', ''], 307 | 'P8': ['Missense', 'Amplification', '', ''] 308 | }, index=['TP53', 'EGFR', 'PTEN', 'KRAS']) 309 | 310 | # Publication-quality markers 311 | markers = { 312 | 'Missense': { 313 | 'marker': 'fill', 314 | 'color': '#2E7D32', # Dark green 315 | 'height': 0.5, 316 | 'zindex': 1 317 | }, 318 | 'Truncating': { 319 | 'marker': 'fill', 320 | 'color': '#000000', # Black 321 | 'height': 0.5, 322 | 'zindex': 1 323 | }, 324 | 'Amplification': { 325 | 'marker': 'fill', 326 | 'color': '#B71C1C', # Dark red 327 | 'zindex': 0 328 | }, 329 | 'Deep Deletion': { 330 | 'marker': 'fill', 331 | 'color': '#0D47A1', # Dark blue 332 | 'zindex': 0 333 | } 334 | } 335 | 336 | # Create figure 337 | op = pyoncoprint.OncoPrint(data) 338 | fig, axes = op.oncoprint( 339 | markers, 340 | figsize=[12, 6], 341 | title="", # No title for publication 342 | gap=[0.2, 0.15], 343 | cell_background="#f5f5f5", 344 | ratio_template="{0:.0%}" 345 | ) 346 | 347 | # Customize for publication 348 | fig.patch.set_facecolor('white') 349 | 350 | # Save as high-resolution image 351 | plt.savefig('oncoprint_publication.pdf', dpi=300, bbox_inches='tight') 352 | plt.savefig('oncoprint_publication.png', dpi=300, bbox_inches='tight') 353 | plt.show() 354 | 355 | Loading Data from Files 356 | ----------------------- 357 | 358 | Working with real data files: 359 | 360 | .. code-block:: python 361 | 362 | # Download and load the TCGA example data 363 | import pandas as pd 364 | import numpy as np 365 | 366 | # Load TCGA data (download from the link above) 367 | df = pd.read_csv('tcga.tsv', sep='\t', header=0) 368 | 369 | # Extract oncoprint data (mutations and CNAs) 370 | df_oncoprint = df[df['track_type'].isin(['MUTATIONS', 'CNA'])].drop(columns=['track_type']).set_index('track_name').fillna('') 371 | 372 | # Clean up mutation names 373 | df_oncoprint.replace('amp_rec', 'Amplification', inplace=True) 374 | df_oncoprint.replace('homdel_rec', 'Deep Deletion', inplace=True) 375 | df_oncoprint.replace('splice', 'Splice Mutation', inplace=True) 376 | 377 | # Define markers for TCGA data 378 | markers = { 379 | 'Amplification': {'marker': 'fill', 'color': 'red', 'zindex': 0}, 380 | 'Deep Deletion': {'marker': 'fill', 'color': 'blue', 'zindex': 0}, 381 | 'Missense Mutation': {'marker': 'fill', 'color': 'green', 'height': 0.5, 'zindex': 1}, 382 | 'Truncating mutation': {'marker': 'fill', 'color': 'black', 'height': 0.5, 'zindex': 1}, 383 | 'Splice Mutation': {'marker': 'fill', 'color': 'orange', 'height': 0.5, 'zindex': 1} 384 | } 385 | 386 | # Create OncoPrint 387 | op = pyoncoprint.OncoPrint(df_oncoprint) 388 | fig, axes = op.oncoprint(markers, figsize=[30, 15], title="TCGA Lung Adenocarcinoma") 389 | 390 | Working with other data formats: 391 | 392 | .. code-block:: python 393 | 394 | # From CSV file 395 | mutation_df = pd.read_csv('mutations.csv', index_col=0) 396 | 397 | # From TSV file (general format) 398 | data = pd.read_csv('data.tsv', sep='\\t', index_col=0) 399 | 400 | # Process and clean data 401 | processed_data = data.replace({'NaN': '', np.nan: ''}) 402 | 403 | # Create OncoPrint 404 | op = pyoncoprint.OncoPrint(processed_data) 405 | fig, axes = op.oncoprint(markers, figsize=[30, 15]) -------------------------------------------------------------------------------- /docs/source/index.rst: -------------------------------------------------------------------------------- 1 | .. PyOncoPrint documentation master file 2 | 3 | PyOncoPrint Documentation 4 | ========================= 5 | 6 | .. image:: https://img.shields.io/pypi/v/pyoncoprint.svg 7 | :target: https://pypi.org/project/pyoncoprint/ 8 | :alt: PyPI version 9 | 10 | .. image:: https://img.shields.io/pypi/dm/pyoncoprint.svg 11 | :target: https://pypi.org/project/pyoncoprint/ 12 | :alt: Downloads 13 | 14 | PyOncoPrint is a Python library for creating OncoPrint visualizations, commonly used in cancer genomics to display mutation and copy number alteration data across multiple samples and genes. 15 | 16 | .. toctree:: 17 | :maxdepth: 2 18 | :caption: Contents: 19 | 20 | installation 21 | quickstart 22 | api 23 | examples 24 | 25 | Features 26 | -------- 27 | 28 | * Create OncoPrint visualizations from pandas DataFrames or numpy arrays 29 | * Support for multiple mutation types with customizable markers 30 | * Add clinical annotations and heatmaps 31 | * Flexible sorting options for genes and samples 32 | * Export high-quality figures for publication 33 | 34 | Citation 35 | -------- 36 | 37 | If you use PyOncoPrint in your research, please cite: 38 | 39 | Jeongbin Park and Nagarajan Paramasivam, "PyOncoPrint: a python package for plotting OncoPrints", *Genomics & Informatics* 21(1): e14 (2023), `doi:10.5808/gi.22079 `_ 40 | 41 | Quick Example 42 | ------------- 43 | 44 | .. code-block:: python 45 | 46 | import pyoncoprint 47 | import pandas as pd 48 | 49 | # Create your mutation matrix 50 | data = pd.DataFrame({ 51 | 'Sample1': ['Missense', '', 'Amplification'], 52 | 'Sample2': ['', 'Truncating', ''], 53 | 'Sample3': ['Missense', 'Missense', 'Deep Deletion'] 54 | }, index=['Gene1', 'Gene2', 'Gene3']) 55 | 56 | # Define mutation markers 57 | markers = { 58 | 'Missense': {'marker': 'fill', 'color': 'green'}, 59 | 'Truncating': {'marker': 'fill', 'color': 'black'}, 60 | 'Amplification': {'marker': 'fill', 'color': 'red'}, 61 | 'Deep Deletion': {'marker': 'fill', 'color': 'blue'} 62 | } 63 | 64 | # Create OncoPrint 65 | op = pyoncoprint.OncoPrint(data) 66 | fig, axes = op.oncoprint(markers) 67 | 68 | Indices and tables 69 | ================== 70 | 71 | * :ref:`genindex` 72 | * :ref:`modindex` 73 | * :ref:`search` 74 | 75 | -------------------------------------------------------------------------------- /docs/source/installation.rst: -------------------------------------------------------------------------------- 1 | Installation 2 | ============ 3 | 4 | Requirements 5 | ------------ 6 | 7 | PyOncoPrint requires Python 3.6+ and the following dependencies: 8 | 9 | * numpy 10 | * pandas 11 | * matplotlib 12 | 13 | Install from PyPI 14 | ----------------- 15 | 16 | The easiest way to install PyOncoPrint is using pip: 17 | 18 | .. code-block:: bash 19 | 20 | pip install pyoncoprint 21 | 22 | Install from Source 23 | ------------------- 24 | 25 | To install the latest development version from GitHub: 26 | 27 | .. code-block:: bash 28 | 29 | git clone https://github.com/pnucolab/pyoncoprint.git 30 | cd pyoncoprint 31 | pip install -e . 32 | 33 | Or directly via pip: 34 | 35 | .. code-block:: bash 36 | 37 | pip install git+https://github.com/pnucolab/pyoncoprint.git 38 | 39 | Verify Installation 40 | ------------------- 41 | 42 | To verify that PyOncoPrint is installed correctly: 43 | 44 | .. code-block:: python 45 | 46 | import pyoncoprint 47 | print(pyoncoprint.__version__) # Should print version number (e.g., '0.2.6') 48 | 49 | # Create a simple test 50 | import pandas as pd 51 | data = pd.DataFrame({ 52 | 'Sample1': ['Missense'], 53 | 'Sample2': ['Truncating'] 54 | }, index=['Gene1']) 55 | 56 | op = pyoncoprint.OncoPrint(data) 57 | print("PyOncoPrint successfully imported and initialized!") -------------------------------------------------------------------------------- /docs/source/quickstart.rst: -------------------------------------------------------------------------------- 1 | Quick Start Guide 2 | ================= 3 | 4 | This guide will walk you through creating your first OncoPrint visualization. 5 | 6 | For real-world examples, download the sample datasets from our `Examples page `_ including TCGA cancer genomics data. 7 | 8 | Basic Usage 9 | ----------- 10 | 11 | 1. Import the library and prepare your data: 12 | 13 | **Note**: PyOncoPrint automatically handles duplicate gene names by concatenating their mutations with a separator (default: ","). 14 | 15 | .. code-block:: python 16 | 17 | import pyoncoprint 18 | import pandas as pd 19 | import matplotlib.pyplot as plt 20 | 21 | # Create a mutation matrix (genes x samples) 22 | data = pd.DataFrame({ 23 | 'Sample1': ['Missense', '', 'Amplification', ''], 24 | 'Sample2': ['', 'Truncating', '', 'Missense'], 25 | 'Sample3': ['Missense', 'Missense', 'Deep Deletion', ''], 26 | 'Sample4': ['Amplification', '', '', 'Truncating'] 27 | }, index=['TP53', 'KRAS', 'EGFR', 'BRAF']) 28 | 29 | 2. Define mutation markers: 30 | 31 | .. code-block:: python 32 | 33 | markers = { 34 | 'Missense': { 35 | 'marker': 'fill', 36 | 'color': 'green', 37 | 'height': 0.5 38 | }, 39 | 'Truncating': { 40 | 'marker': 'fill', 41 | 'color': 'black', 42 | 'height': 0.5 43 | }, 44 | 'Amplification': { 45 | 'marker': 'fill', 46 | 'color': 'red' 47 | }, 48 | 'Deep Deletion': { 49 | 'marker': 'fill', 50 | 'color': 'blue' 51 | } 52 | } 53 | 54 | 3. Create the OncoPrint: 55 | 56 | .. code-block:: python 57 | 58 | # Initialize OncoPrint object 59 | op = pyoncoprint.OncoPrint(data) 60 | 61 | # Generate the plot 62 | fig, axes = op.oncoprint( 63 | markers, 64 | figsize=[20, 10], 65 | title="My First OncoPrint" 66 | ) 67 | 68 | plt.show() 69 | 70 | Adding Clinical Annotations 71 | ---------------------------- 72 | 73 | You can add clinical data as annotation tracks: 74 | 75 | .. code-block:: python 76 | 77 | # Create annotation data 78 | import numpy as np 79 | 80 | # Categorical annotation 81 | cancer_type = pd.DataFrame( 82 | ['Lung', 'Lung', 'Breast', 'Colon'], 83 | columns=['Cancer Type'], 84 | index=['Sample1', 'Sample2', 'Sample3', 'Sample4'] 85 | ).T 86 | 87 | # Numerical annotation 88 | age = pd.DataFrame( 89 | [65, 72, 58, 61], 90 | columns=['Sample1', 'Sample2', 'Sample3', 'Sample4'], 91 | index=['Age'] 92 | ) 93 | 94 | # Define annotation styles 95 | annotations = { 96 | 'Cancer Type': { 97 | 'annotations': cancer_type, 98 | 'colors': { 99 | 'Lung': 'lightblue', 100 | 'Breast': 'pink', 101 | 'Colon': 'lightgreen' 102 | }, 103 | 'order': 0 104 | }, 105 | 'Age': { 106 | 'annotations': age, 107 | 'color': 'orange', 108 | 'order': 1 109 | } 110 | } 111 | 112 | # Create OncoPrint with annotations 113 | fig, axes = op.oncoprint( 114 | markers, 115 | annotations=annotations, 116 | figsize=[20, 12] 117 | ) 118 | 119 | Adding Heatmaps 120 | --------------- 121 | 122 | You can include expression or other continuous data as heatmaps: 123 | 124 | .. code-block:: python 125 | 126 | # Create expression data 127 | expression_data = pd.DataFrame( 128 | np.random.randn(4, 4), 129 | index=['TP53', 'KRAS', 'EGFR', 'BRAF'], 130 | columns=['Sample1', 'Sample2', 'Sample3', 'Sample4'] 131 | ) 132 | 133 | # Define heatmap configuration 134 | heatmaps = { 135 | 'Gene Expression': { 136 | 'heatmap': expression_data, 137 | 'cmap': 'RdBu_r', # Red-Blue colormap 138 | 'vmin': -2, 139 | 'vmax': 2 140 | } 141 | } 142 | 143 | # Create OncoPrint with heatmap 144 | fig, axes = op.oncoprint( 145 | markers, 146 | heatmaps=heatmaps, 147 | figsize=[20, 15] 148 | ) 149 | 150 | Customization Options 151 | --------------------- 152 | 153 | The `oncoprint()` method supports many customization options: 154 | 155 | .. code-block:: python 156 | 157 | fig, axes = op.oncoprint( 158 | markers, 159 | annotations=annotations, 160 | heatmaps=heatmaps, 161 | title="Customized OncoPrint", 162 | figsize=[30, 20], 163 | gene_sort_method='default', # Sort genes by frequency 164 | sample_sort_method='default', # Sort samples by mutations 165 | topplot=True, # Show mutation frequency plot on top 166 | rightplot=True, # Show gene alteration plot on right 167 | legend=True, # Show legend 168 | cell_background="#dddddd", # Background color for empty cells 169 | gap=[0.3, 0.1], # Gap between cells (x, y) 170 | ratio_template="{0:.0%}" # Format for gene frequency labels 171 | ) -------------------------------------------------------------------------------- /example_data/test1.tsv: -------------------------------------------------------------------------------- 1 | track_name track_type TCGA-75-5122 TCGA-91-6836 TCGA-55-7576 TCGA-MN-A4N5 TCGA-05-4250 TCGA-44-7661 TCGA-55-8094 TCGA-55-7910 TCGA-99-8028 TCGA-55-7283 TCGA-05-4433 TCGA-44-7672 TCGA-50-5941 TCGA-50-8459 TCGA-55-7815 TCGA-67-3774 TCGA-MP-A4TF TCGA-MP-A4TK TCGA-44-A479 TCGA-55-8092 TCGA-49-AAR9 TCGA-69-8255 TCGA-55-8507 TCGA-73-4668 TCGA-91-6835 TCGA-49-6745 TCGA-55-1592 TCGA-86-7954 TCGA-95-8494 TCGA-NJ-A55R TCGA-44-6145 TCGA-55-8090 TCGA-78-7539 TCGA-95-7039 TCGA-05-4249 TCGA-05-4427 TCGA-05-4417 TCGA-86-8359 TCGA-95-7567 TCGA-MP-A4TI TCGA-86-A4JF TCGA-86-8056 TCGA-64-5815 TCGA-44-8117 TCGA-05-4415 TCGA-86-7713 TCGA-99-8032 TCGA-35-3615 TCGA-64-5774 TCGA-69-8253 TCGA-55-8616 TCGA-55-8302 TCGA-67-4679 TCGA-64-5778 TCGA-44-6776 TCGA-55-7284 TCGA-NJ-A4YI TCGA-91-6849 TCGA-69-7980 TCGA-55-8508 TCGA-49-4506 TCGA-50-5936 TCGA-55-7907 TCGA-86-8054 TCGA-49-AARO TCGA-55-A490 TCGA-J2-A4AG TCGA-05-4390 TCGA-05-4405 TCGA-55-8299 TCGA-95-A4VK TCGA-05-4418 TCGA-55-8097 TCGA-93-7347 TCGA-64-1677 TCGA-55-7281 TCGA-55-7726 TCGA-73-4670 TCGA-86-7953 TCGA-93-A4JO TCGA-91-6828 TCGA-69-8254 TCGA-44-A47F TCGA-44-3917 TCGA-55-8203 TCGA-69-7978 TCGA-73-4677 TCGA-MP-A4T7 TCGA-78-7160 TCGA-78-7161 TCGA-NJ-A4YP TCGA-4B-A93V TCGA-05-4244 TCGA-05-4395 TCGA-05-4403 TCGA-44-A47A TCGA-44-6144 TCGA-44-6146 TCGA-44-7659 TCGA-44-7671 TCGA-49-AARQ TCGA-49-4505 TCGA-49-4510 TCGA-50-5051 TCGA-50-5932 TCGA-50-5933 TCGA-50-7109 TCGA-53-7813 TCGA-55-A494 TCGA-55-1595 TCGA-55-6642 TCGA-55-6970 TCGA-55-6975 TCGA-55-6983 TCGA-55-6984 TCGA-55-7725 TCGA-55-7728 TCGA-55-7911 TCGA-55-7914 TCGA-55-8207 TCGA-55-8512 TCGA-55-8514 TCGA-55-8615 TCGA-62-A46R TCGA-62-A46S TCGA-62-8398 TCGA-64-5775 TCGA-67-3773 TCGA-69-7973 TCGA-69-7974 TCGA-73-4662 TCGA-73-7498 TCGA-J2-8194 TCGA-75-5126 TCGA-75-6206 TCGA-75-7027 TCGA-75-7030 TCGA-L9-A443 TCGA-MP-A4SY TCGA-MP-A4T4 TCGA-MP-A4T8 TCGA-MP-A4TD TCGA-MP-A4TE TCGA-78-7145 TCGA-78-7148 TCGA-78-7166 TCGA-78-7167 TCGA-78-7540 TCGA-78-8655 TCGA-NJ-A4YG TCGA-NJ-A55O TCGA-80-5608 TCGA-83-5908 TCGA-86-A456 TCGA-86-8076 TCGA-86-8674 TCGA-93-8067 TCGA-95-A4VN TCGA-95-A4VP TCGA-95-7562 TCGA-97-A4M0 TCGA-97-A4M5 TCGA-97-7554 TCGA-97-7938 TCGA-97-7941 TCGA-97-8176 TCGA-97-8179 TCGA-99-8025 TCGA-99-8033 TCGA-55-8505 TCGA-62-8399 TCGA-62-A46O TCGA-91-6840 TCGA-05-4420 TCGA-49-AAR4 TCGA-78-7154 TCGA-55-6981 TCGA-62-A46P TCGA-78-8660 TCGA-69-7765 TCGA-44-2662 TCGA-MN-A4N1 TCGA-50-5930 TCGA-55-8511 TCGA-55-6968 TCGA-53-A4EZ TCGA-55-6979 TCGA-49-AARN TCGA-75-5146 TCGA-44-6774 TCGA-05-5428 TCGA-05-4389 TCGA-55-7903 TCGA-55-7913 TCGA-05-4410 TCGA-44-2666 TCGA-50-5044 TCGA-50-5942 TCGA-50-5946 TCGA-50-6594 TCGA-62-A46V TCGA-62-A472 TCGA-78-7153 TCGA-78-7537 TCGA-78-7633 TCGA-78-8662 TCGA-80-5607 TCGA-86-7714 TCGA-91-A4BD TCGA-97-A4M7 TCGA-44-3918 TCGA-73-A9RS TCGA-55-8506 TCGA-05-4382 TCGA-L4-A4E6 TCGA-L9-A8F4 TCGA-97-7546 TCGA-J2-8192 TCGA-78-7220 TCGA-55-8620 TCGA-44-6777 TCGA-62-8394 TCGA-50-6592 TCGA-35-4123 TCGA-67-3771 TCGA-38-4631 TCGA-78-7146 TCGA-50-5944 TCGA-64-1680 TCGA-86-8672 TCGA-55-8087 TCGA-55-A4DF TCGA-86-8073 TCGA-05-4434 TCGA-71-6725 TCGA-86-8358 TCGA-44-3396 TCGA-53-7624 TCGA-38-4626 TCGA-49-4486 TCGA-75-5125 TCGA-97-8177 TCGA-49-4488 TCGA-38-4625 TCGA-49-6744 TCGA-78-7536 TCGA-35-4122 TCGA-91-7771 TCGA-64-1676 TCGA-05-5425 TCGA-75-6211 TCGA-44-6778 TCGA-91-A4BC TCGA-50-6591 TCGA-53-7626 TCGA-44-A47B TCGA-67-6215 TCGA-75-7031 TCGA-69-7979 TCGA-44-2656 TCGA-49-6761 TCGA-55-A493 TCGA-55-7727 TCGA-97-A4LX TCGA-78-7535 TCGA-55-A48Z TCGA-50-5049 TCGA-L9-A50W TCGA-97-8547 TCGA-86-7701 TCGA-55-6985 TCGA-49-AARE TCGA-86-7955 TCGA-44-5644 TCGA-95-7043 TCGA-05-4396 TCGA-78-7149 TCGA-69-A59K TCGA-86-8673 TCGA-78-7155 TCGA-55-8510 TCGA-64-1679 TCGA-MN-A4N4 TCGA-49-AAR0 TCGA-49-4490 TCGA-MP-A4SW TCGA-91-6848 TCGA-91-6829 TCGA-86-7711 TCGA-55-6972 TCGA-55-6971 TCGA-73-7499 TCGA-64-1681 TCGA-05-4402 TCGA-55-7573 TCGA-91-6847 TCGA-50-6673 TCGA-05-4430 TCGA-44-8119 TCGA-55-1594 TCGA-97-8174 TCGA-05-4426 TCGA-78-8640 TCGA-38-7271 TCGA-NJ-A4YQ TCGA-05-4398 TCGA-44-3398 TCGA-44-7662 TCGA-55-6712 TCGA-55-8089 TCGA-05-4424 TCGA-38-4628 TCGA-86-8074 TCGA-44-7660 TCGA-50-5045 TCGA-55-A4DG TCGA-55-8204 TCGA-55-8614 TCGA-62-A471 TCGA-62-8395 TCGA-62-8402 TCGA-69-7764 TCGA-J2-A4AD TCGA-L4-A4E5 TCGA-L9-A7SV TCGA-MP-A4TC TCGA-86-6851 TCGA-44-A4SS TCGA-44-8120 TCGA-55-6969 TCGA-91-6830 TCGA-05-4422 TCGA-49-4487 TCGA-49-4507 TCGA-50-5935 TCGA-55-8208 TCGA-62-A46U TCGA-73-4676 TCGA-MP-A4SV TCGA-80-5611 TCGA-86-6562 TCGA-44-7670 TCGA-95-7947 TCGA-05-4384 TCGA-05-4397 TCGA-05-4425 TCGA-05-4432 TCGA-05-5423 TCGA-05-5429 TCGA-05-5715 TCGA-35-5375 TCGA-38-A44F TCGA-38-4627 TCGA-38-4632 TCGA-38-6178 TCGA-44-A4SU TCGA-44-A47G TCGA-44-2655 TCGA-44-2657 TCGA-44-2659 TCGA-44-2665 TCGA-44-2668 TCGA-44-3919 TCGA-44-4112 TCGA-44-5643 TCGA-44-5645 TCGA-44-6148 TCGA-44-6775 TCGA-44-6779 TCGA-44-7667 TCGA-44-7669 TCGA-49-AAQV TCGA-49-AAR2 TCGA-49-AAR3 TCGA-49-AARR TCGA-49-4494 TCGA-49-4501 TCGA-49-4512 TCGA-49-4514 TCGA-49-6742 TCGA-49-6743 TCGA-49-6767 TCGA-50-5055 TCGA-50-5066 TCGA-50-5068 TCGA-50-5072 TCGA-50-5931 TCGA-50-5939 TCGA-50-6590 TCGA-50-6593 TCGA-50-6595 TCGA-50-6597 TCGA-50-8457 TCGA-50-8460 TCGA-55-A48X TCGA-55-A48Y TCGA-55-A57B TCGA-55-A491 TCGA-55-A492 TCGA-55-1596 TCGA-55-5899 TCGA-55-6543 TCGA-55-6978 TCGA-55-6980 TCGA-55-6982 TCGA-55-6986 TCGA-55-6987 TCGA-55-7570 TCGA-55-7574 TCGA-55-7724 TCGA-55-7994 TCGA-55-7995 TCGA-55-8085 TCGA-55-8091 TCGA-55-8096 TCGA-55-8205 TCGA-55-8206 TCGA-55-8301 TCGA-55-8513 TCGA-55-8619 TCGA-55-8621 TCGA-62-A46Y TCGA-62-A470 TCGA-62-8397 TCGA-64-5779 TCGA-64-5781 TCGA-67-3770 TCGA-67-3772 TCGA-67-6216 TCGA-67-6217 TCGA-69-7760 TCGA-69-7761 TCGA-69-7763 TCGA-73-4658 TCGA-73-4659 TCGA-73-4666 TCGA-73-4675 TCGA-J2-A4AE TCGA-75-5147 TCGA-75-6203 TCGA-75-6205 TCGA-75-6207 TCGA-75-6212 TCGA-75-6214 TCGA-75-7025 TCGA-L9-A5IP TCGA-L9-A444 TCGA-L9-A743 TCGA-MP-A4T2 TCGA-MP-A4T6 TCGA-MP-A4T9 TCGA-MP-A4TA TCGA-MP-A4TH TCGA-MP-A4TJ TCGA-MP-A5C7 TCGA-78-7147 TCGA-78-7150 TCGA-78-7152 TCGA-78-7156 TCGA-78-7158 TCGA-78-7159 TCGA-78-7162 TCGA-78-7163 TCGA-78-7542 TCGA-78-8648 TCGA-NJ-A4YF TCGA-NJ-A7XG TCGA-NJ-A55A TCGA-O1-A52J TCGA-S2-AA1A TCGA-86-A4P7 TCGA-86-A4P8 TCGA-86-8055 TCGA-86-8075 TCGA-86-8278 TCGA-86-8279 TCGA-86-8280 TCGA-86-8281 TCGA-86-8585 TCGA-86-8668 TCGA-86-8669 TCGA-86-8671 TCGA-91-6831 TCGA-91-8496 TCGA-91-8497 TCGA-91-8499 TCGA-93-A4JN TCGA-93-A4JP TCGA-93-A4JQ TCGA-93-7348 TCGA-95-7944 TCGA-95-7948 TCGA-95-8039 TCGA-97-A4M1 TCGA-97-A4M2 TCGA-97-A4M3 TCGA-97-A4M6 TCGA-97-7547 TCGA-97-7552 TCGA-97-7553 TCGA-97-7937 TCGA-97-8171 TCGA-97-8172 TCGA-97-8175 TCGA-97-8552 TCGA-99-AA5R TCGA-99-7458 2 | KRAS CNA amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec 3 | HRAS CNA Deep Deletion amp_rec Deep Deletion Deep Deletion Deep Deletion 4 | BRAF CNA amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec 5 | RAF1 CNA amp_rec 6 | MAP3K1 CNA Amplification Amplification Amplification homdel_rec Amplification homdel_rec homdel_rec 7 | MAP3K2 CNA Amplification 8 | MAP3K3 CNA Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification 9 | MAP3K4 CNA Deep Deletion Deep Deletion Deep Deletion Amplification Deep Deletion 10 | MAP3K5 CNA Deep Deletion Deep Deletion Amplification Amplification Deep Deletion 11 | MAP2K1 CNA Amplification 12 | MAP2K2 CNA Deep Deletion Deep Deletion Deep Deletion 13 | MAP2K3 CNA Deep Deletion Deep Deletion Amplification Amplification Amplification Amplification Deep Deletion Deep Deletion 14 | MAP2K4 CNA homdel_rec homdel_rec homdel_rec homdel_rec homdel_rec homdel_rec Amplification 15 | MAP2K5 CNA Amplification Deep Deletion 16 | MAPK1 CNA amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec amp_rec 17 | MAPK3 CNA Amplification Amplification Amplification Amplification Amplification 18 | MAPK4 CNA Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion 19 | MAPK6 CNA Deep Deletion Deep Deletion Deep Deletion Deep Deletion 20 | MAPK7 CNA Amplification Amplification Deep Deletion Deep Deletion Deep Deletion Amplification Amplification Amplification Amplification Deep Deletion 21 | MAPK8 CNA Amplification Amplification Deep Deletion Deep Deletion Deep Deletion Deep Deletion 22 | MAPK9 CNA Deep Deletion Amplification Amplification Amplification Amplification Amplification Deep Deletion Amplification Deep Deletion Amplification Amplification Amplification Deep Deletion 23 | MAPK12 CNA Deep Deletion Amplification Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Deep Deletion Amplification Deep Deletion Deep Deletion 24 | MAPK14 CNA Amplification Amplification Amplification Amplification 25 | DAB2 CNA Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification 26 | RASSF1 CNA 27 | RAB25 CNA Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification Amplification 28 | KRAS MUTATIONS Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) 29 | HRAS MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative driver) Missense Mutation (putative passenger) 30 | BRAF MUTATIONS Missense Mutation (putative driver) Truncating mutation (putative passenger) splice Missense Mutation (putative passenger) Inframe Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 31 | RAF1 MUTATIONS Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 32 | MAP3K1 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative driver) Missense Mutation (putative passenger) 33 | MAP3K2 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 34 | MAP3K3 MUTATIONS Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 35 | MAP3K4 MUTATIONS Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) splice Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 36 | MAP3K5 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 37 | MAP2K1 MUTATIONS Missense Mutation (putative driver) Truncating mutation (putative passenger) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative driver) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 38 | MAP2K2 MUTATIONS Missense Mutation (putative passenger) 39 | MAP2K3 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) splice Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 40 | MAP2K4 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) splice_rec Truncating mutation (putative driver) splice_rec Missense Mutation (putative passenger) Truncating mutation (putative driver) Missense Mutation (putative driver) 41 | MAP2K5 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 42 | MAPK1 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 43 | MAPK3 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 44 | MAPK4 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) 45 | MAPK6 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) 46 | MAPK7 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 47 | MAPK8 MUTATIONS Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 48 | MAPK9 MUTATIONS Missense Mutation (putative passenger) splice Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 49 | MAPK12 MUTATIONS Missense Mutation (putative passenger) 50 | MAPK14 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Truncating mutation (putative passenger) splice 51 | DAB2 MUTATIONS Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) splice Missense Mutation (putative passenger) Truncating mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) Missense Mutation (putative passenger) 52 | RASSF1 MUTATIONS Missense Mutation (putative passenger) splice 53 | RAB25 MUTATIONS Missense Mutation (putative passenger) Truncating mutation (putative passenger) Truncating mutation (putative passenger) 54 | KRAS MRNA 55 | HRAS MRNA 56 | BRAF MRNA 57 | RAF1 MRNA 58 | MAP3K1 MRNA 59 | MAP3K2 MRNA 60 | MAP3K3 MRNA 61 | MAP3K4 MRNA 62 | MAP3K5 MRNA 63 | MAP2K1 MRNA 64 | MAP2K2 MRNA 65 | MAP2K3 MRNA 66 | MAP2K4 MRNA 67 | MAP2K5 MRNA 68 | MAPK1 MRNA 69 | MAPK3 MRNA 70 | MAPK4 MRNA 71 | MAPK6 MRNA 72 | MAPK7 MRNA 73 | MAPK8 MRNA 74 | MAPK9 MRNA 75 | MAPK12 MRNA 76 | MAPK14 MRNA 77 | DAB2 MRNA 78 | RASSF1 MRNA 79 | RAB25 MRNA 80 | KRAS PROTEIN 81 | HRAS PROTEIN 82 | BRAF PROTEIN 83 | RAF1 PROTEIN 84 | MAP3K1 PROTEIN 85 | MAP3K2 PROTEIN 86 | MAP3K3 PROTEIN 87 | MAP3K4 PROTEIN 88 | MAP3K5 PROTEIN 89 | MAP2K1 PROTEIN 90 | MAP2K2 PROTEIN 91 | MAP2K3 PROTEIN 92 | MAP2K4 PROTEIN 93 | MAP2K5 PROTEIN 94 | MAPK1 PROTEIN 95 | MAPK3 PROTEIN 96 | MAPK4 PROTEIN 97 | MAPK6 PROTEIN 98 | MAPK7 PROTEIN 99 | MAPK8 PROTEIN 100 | MAPK9 PROTEIN 101 | MAPK12 PROTEIN 102 | MAPK14 PROTEIN 103 | DAB2 PROTEIN 104 | RASSF1 PROTEIN 105 | RAB25 PROTEIN 106 | KRAS STRUCTURAL_VARIANT sv 107 | HRAS STRUCTURAL_VARIANT 108 | BRAF STRUCTURAL_VARIANT 109 | RAF1 STRUCTURAL_VARIANT 110 | MAP3K1 STRUCTURAL_VARIANT 111 | MAP3K2 STRUCTURAL_VARIANT sv_rec 112 | MAP3K3 STRUCTURAL_VARIANT 113 | MAP3K4 STRUCTURAL_VARIANT 114 | MAP3K5 STRUCTURAL_VARIANT sv 115 | MAP2K1 STRUCTURAL_VARIANT 116 | MAP2K2 STRUCTURAL_VARIANT 117 | MAP2K3 STRUCTURAL_VARIANT 118 | MAP2K4 STRUCTURAL_VARIANT sv_rec 119 | MAP2K5 STRUCTURAL_VARIANT 120 | MAPK1 STRUCTURAL_VARIANT sv sv 121 | MAPK3 STRUCTURAL_VARIANT 122 | MAPK4 STRUCTURAL_VARIANT 123 | MAPK6 STRUCTURAL_VARIANT 124 | MAPK7 STRUCTURAL_VARIANT 125 | MAPK8 STRUCTURAL_VARIANT 126 | MAPK9 STRUCTURAL_VARIANT 127 | MAPK12 STRUCTURAL_VARIANT 128 | MAPK14 STRUCTURAL_VARIANT 129 | DAB2 STRUCTURAL_VARIANT 130 | RASSF1 STRUCTURAL_VARIANT 131 | RAB25 STRUCTURAL_VARIANT sv 132 | KRAS HEATMAP MRNA_EXPRESSION Z-SCORE 5.9959 10.8738 2.2105 2.0675 5.3943 3.2589 12.8384 0.7326 0.7117 0.7026 2.8756 1.9783 3.0366 -0.0661 3.6727 1.0036 46.4916 0.3049 4.4689 1.0634 29.4742 -0.5728 1.8778 5.5716 3.5456 8.2031 3.9262 5.4721 4.6478 0.1123 0.1515 8.0209 0.6272 -0.1068 5.2224 2.446 2.826 -0.6508 1.5376 0.1478 2.2985 1.6738 0.3561 1.135 2.7383 3.5498 0.1739 -0.3485 0.0863 -0.3745 1.4951 1.2232 0.5113 -0.7657 1.404 1.0198 0.4801 -1.2293 1.3359 0.2889 -0.3665 0.6597 2.6239 2.2577 -0.7264 1.7587 1.8423 1.2775 -0.4632 -0.8326 -0.3808 -0.1314 1.9463 -0.0433 -0.0441 0.7451 1.2146 1.0379 0.6309 0.0607 2.0187 0.0828 1.2209 -0.3506 -0.2342 -0.4316 0.4829 0.1667 -0.457 -0.6716 0.8753 2.6562 -0.1325 -0.2857 1.7741 -0.2481 0.2805 -1.1629 0.25 -0.1084 -0.3825 1.6685 0.4616 0.5681 1.1997 3.2932 1.3273 1.392 0.2059 0.1154 0.2524 2.2299 2.7734 -0.1772 2.5391 0.233 0.3415 -0.598 -0.7259 0.8637 0.7725 1.0073 1.1948 0.5313 0.9827 1.7216 0.6588 0.8829 -0.0919 0.1321 0.1919 -0.376 5.4631 -0.1283 0.7925 0.8418 -0.315 0.697 0.0443 1.3461 1.0507 1.1949 -0.0771 0.5301 1.4607 0.1681 0.4156 -0.2125 0.5312 1.6225 -0.0226 -0.1384 -0.2257 1.0703 0.4596 -0.3098 -0.1257 0.9843 0.0853 5.3291 0.1312 -0.749 -0.0014 -0.2911 -0.4175 0.0255 0.6238 -0.2909 2.8486 -0.294 0.0485 -0.6572 0.2976 0.4606 0.2395 -0.9356 -0.2377 -0.4301 0.248 -0.3104 -1.4182 -0.1092 0.5692 -0.658 -1.1978 0.7377 -0.4987 0.0002 -0.1085 -0.0389 3.005 -0.3942 -1.0945 -1.0664 -1.2365 -0.9595 -0.6949 -0.1561 -0.1655 -0.4336 -0.6569 -0.2388 -0.5706 -0.0816 -0.2288 -1.128 -0.2718 -0.2731 0.5324 -0.7446 0.2821 -0.7367 -1.1183 0.1906 0.2617 3.9765 -0.2461 -0.1183 -0.4502 1.5495 -0.193 -0.8029 0.2262 1.2825 -0.1862 -0.8218 -0.8844 -0.9817 1.1544 -0.1327 -0.0885 -0.2137 0.0179 -0.9046 0.2723 -0.477 -0.6857 1.3203 -0.822 1.2885 -0.2653 -0.007 0.2883 0.1164 0.9335 -0.7021 -0.6273 -0.4681 0.0296 -0.6129 -0.3299 0.771 2.8092 1.7289 0.2016 -0.6463 -0.5454 -0.1363 1.9753 -0.3466 0.1212 -0.9879 -0.7475 -0.7561 -0.7564 -0.6035 0.9476 1.0215 -1.1859 -1.5405 0.5459 -0.3643 2.7427 -0.9066 1.6308 -0.2713 4.9542 -1.0621 -0.3741 -0.4504 -1.4777 -0.8332 -0.1614 -0.2637 1.4138 -0.8999 -0.3165 0.4096 -0.378 0.2803 0.0612 -0.8436 0.9872 0.9804 0.6819 0.627 0.6587 -0.0967 -1.4207 -0.8196 -0.303 -1.431 -0.3335 0.6695 -0.3331 0.2852 -0.6395 1.9335 -0.3798 -0.6152 0.3311 -0.2564 -1.4376 -0.5959 -0.9318 -0.1503 0.358 0.0232 0.566 -0.8264 -0.3923 -0.0586 -0.9765 1.1288 0.3479 -0.9097 -0.634 -0.702 -0.0682 -0.0762 -1.256 2.3518 -0.0132 0.0748 -0.2702 0.5958 -1.4786 0.8772 10.0927 -1.0237 -0.1606 -0.7806 0.7009 -0.0353 -0.311 -0.5273 0.419 -1.2317 -0.5089 -0.4344 -0.9232 -0.4109 -1.2887 0.1405 -0.9303 0.2946 -0.3185 -0.3361 0.6198 -0.1464 0.7769 6.9447 -0.6159 -1.313 -0.6235 -0.1591 0.9241 2.5504 -1.1373 -1.3499 -0.9889 -0.8939 -0.6956 -0.3613 0.1082 0.6392 0.5394 -0.4668 0.0453 -0.6234 0.0248 -0.7435 1.9094 0.2077 -0.8627 -0.2156 -0.647 -0.7132 -1.2394 -0.4096 -1.1751 -0.3107 -0.1184 -0.842 -0.5409 -0.5487 -0.7208 -0.4429 -0.86 1.0495 0.0472 1.1281 -1.0266 -0.0227 -0.4577 0.6105 0.7388 -0.2919 0.8532 -0.1716 -0.2978 -0.3094 -0.5161 -0.685 -0.6185 -0.5259 -0.6928 -0.5309 0.4196 1.556 -0.9026 0.2408 -0.6795 -0.4364 -0.2712 -0.1195 -0.7635 0.2288 0.2262 0.3621 -0.191 1.172 -0.4129 -0.0991 -0.8707 -0.4152 -0.8593 -0.92 -0.5721 -0.9393 -0.6924 -0.7112 1.2844 -1.0549 -0.8247 -1.3371 0.0253 -1.1746 -0.5145 0.5341 0.3412 -1.4538 1.8584 0.1379 -0.4084 -0.3361 0.9544 -0.5126 -1.146 -0.5647 -0.8145 0.3724 -0.356 -0.4718 -1.5445 -0.1464 -0.0558 -0.9016 -0.1551 -0.5188 -0.3713 -1.0937 -0.5174 0.3012 -0.0854 -0.9893 0.3772 -1.0429 0.8697 -0.7861 -0.8162 1.5488 -1.0865 -0.7378 -0.6645 0.0625 -0.6491 -0.6246 -0.7367 -1.2242 -0.7162 0.1127 -1.1248 0.237 0.6429 -0.619 -0.251 -0.8257 1.7879 0.4693 -0.8262 -1.1207 0.6411 133 | HRAS HEATMAP MRNA_EXPRESSION Z-SCORE -0.8059 -1.2021 -0.5957 0.3468 -0.4467 0.4396 0.215 -0.5369 0.0934 -0.6172 -0.3714 -0.3717 -0.7345 0.9824 -1.737 -0.1661 0.4525 0.2701 -1.0458 -0.6976 -0.2395 0.8136 0.2933 -0.6593 -1.1326 -0.6001 -0.8827 -0.2041 0.2178 0.2215 -0.205 0.5936 0.5353 -0.4933 -0.7215 -0.5172 -0.4236 0.7458 -0.5947 0.4608 -0.0813 -0.5449 -0.5228 -0.5907 1.0298 0.2171 1.2404 0.3098 0.5224 0.913 0.9869 -0.7009 -1.0805 0.659 0.3461 -0.5998 -0.0394 0.142 -0.1461 1.5847 -0.457 -0.727 -1.1374 0.0539 -0.0285 0.0094 0.7571 -0.3987 -0.9232 -0.0531 -0.5236 0.1034 -0.1142 -0.3289 0.1479 0.4961 -0.1982 -0.0178 -1.0076 0.3049 -0.8216 -0.6414 0.2224 -0.94 -0.6197 0.3827 -1.2969 -0.2099 0.3108 1.4152 -0.9284 0.5484 -0.3899 0.1227 -0.3435 -0.1148 1.2846 4.3208 -0.8476 0.1021 2.1349 -0.0858 -0.6881 0.3684 -0.1714 0.5003 -0.6861 -0.8022 -1.0886 0.2843 0.191 0.268 -1.6691 1.5655 0.274 -1.2311 -0.6844 0.0985 2.2384 1.1637 -0.8079 -0.2649 -0.1404 2.1135 -0.2911 -0.1996 -0.6542 0.0274 -0.05 -0.6463 -0.1531 -0.6536 0.7659 -0.2718 1.4003 -0.4075 -0.6921 0.5963 0.4532 -0.0488 -1.1068 -0.3134 2.713 0.6383 0.5627 0.3583 -0.1774 0.8559 1.9181 -0.1662 -0.9012 -0.3511 1.1905 1.5179 0.6967 2.7148 2.5476 -0.4795 -0.1751 -0.6256 -1.1792 -0.4448 0.3727 -0.3949 0.8745 -0.5866 1.6411 -1.2663 -1.4416 -1.4639 2.2051 2.7837 -0.7242 0.2456 1.3277 0.7064 -1.4403 -1.0405 0.2428 -1.1877 -0.2126 -0.3069 -0.4007 -0.7569 0.8014 0.1522 -0.5594 -1.2114 -0.539 -0.9379 0.2071 -0.6571 -0.8652 4.3516 -1.2539 -1.0742 -1.0697 -0.0738 -0.4639 0.4226 0.9747 -0.6449 0.2085 -0.4852 -1.1535 0.8565 -0.8516 -0.2134 -0.2257 0.1136 -0.5575 -0.2317 -0.2212 -1.1931 -0.8644 -0.8351 3.6811 -0.8845 0.1635 -1.1935 0.5516 -1.1737 -0.4948 -0.5229 -0.6678 -0.9285 2.0272 -0.1619 0.4366 -1.039 -1.1524 0.4163 0.1357 0.178 -0.523 -0.4571 0.9181 -0.4967 0.1656 0.1871 1.5689 -1.0752 -0.5304 -0.1949 -1.0521 -0.5333 -1.2954 0.2137 1.4276 0.1929 1.6777 -0.9001 -0.1644 0.2046 0.0827 -0.1553 -0.7135 0.6342 0.4111 -1.3666 -0.5949 1.5433 0.9962 -0.4291 -0.1328 0.2313 -1.0944 0.1374 1.2328 -0.736 -0.2977 -0.529 -0.2613 0.7489 -0.8967 -0.5955 -1.2921 -0.608 -0.1984 -1.1183 2.2807 -0.5771 -0.2378 -0.0447 -1.0138 -1.1065 0.0739 -0.2522 0.0835 -0.4575 0.0486 -1.2459 0.0145 -1.2255 -0.3645 1.1805 -0.5084 -1.0322 -0.1876 -1.0233 -0.7888 -0.8856 -0.52 -0.6321 -0.2381 -0.8059 -0.8217 -1.2309 0.1438 -0.1286 1.8475 0.1468 -1.3846 1.2504 -0.1477 0.2234 0.3462 0.8703 0.3797 -0.3038 -0.0066 -0.8193 0.3397 -0.637 -0.5948 0.8414 0.7918 -0.6856 0.2922 -0.4253 1.5618 -0.5735 -0.3817 -0.215 -0.5244 -0.0357 0.1405 -0.5355 0.6644 -0.3356 -0.4087 1.2933 0.1657 0.4448 -0.9195 -0.3221 -0.7458 0.4081 0.3097 -0.4266 -0.5736 -1.0838 -0.6236 -0.6805 -0.0219 -0.5591 -0.7792 -0.8534 -0.5596 -0.517 0.5975 6.2338 -0.9299 -0.6449 -0.3876 -0.5133 0.747 0.7895 -0.2725 4.2201 -0.0578 0.1778 3.51 -0.0434 1.6934 0.9181 -0.3878 -1.1591 -0.5497 0.0577 -0.5222 -0.1673 -0.431 1.1899 -0.8574 -0.3599 -0.7144 0.5564 1.3081 -0.7389 -1.0792 -0.3985 -0.4249 -0.8897 0.6032 3.1918 -1.2513 -0.4448 0.0798 0.0771 -0.6493 0.2112 0.0078 -0.9146 -0.4005 0.0143 -1.4135 -1.3478 -0.7842 -0.2499 -0.1949 -0.997 0.6966 -0.8994 -0.447 -0.5577 -0.4523 0.6141 -0.3744 0.5703 0.181 -0.4888 -0.3031 -0.5784 -0.8192 -0.6219 -0.5446 -0.9428 -0.9063 -0.6933 -0.2528 -0.3236 -0.5782 0.3281 -0.3029 0.1065 -0.7042 -0.3396 -1.1802 -0.9645 2.7827 -0.8687 -0.1183 -0.2301 0.047 -0.0535 -0.734 0.3973 -0.3605 -0.62 -0.754 -0.0615 -0.7705 -0.2748 -0.4828 -0.9504 -0.0725 -0.0442 2.6515 3.4828 -0.2508 0.5474 0.9223 -0.3626 -1.0807 -0.5958 0.1831 -0.5938 -0.9994 -0.7219 -0.6911 0.1766 -0.7858 -0.2748 0.1319 -0.9305 -0.1551 -0.4157 0.6913 -0.8985 -0.0322 2.0451 -0.2543 0.0723 0.8686 -0.6143 0.9033 0.514 -0.5102 -0.4659 0.0031 0.738 -0.3554 -0.5872 -1.0541 -1.1237 -0.4181 -0.6834 -0.233 0.6283 -0.2857 0.0663 -0.8333 134 | BRAF HEATMAP MRNA_EXPRESSION Z-SCORE -0.6797 5.2897 1.1695 -0.5823 0.6957 0.3878 -0.2288 6.457 -0.0376 0.1552 -0.7719 -0.806 -0.1669 -0.7157 1.3445 -1.4305 -0.6077 -0.472 0.9694 -0.5062 0.234 0.4231 0.1911 1.1261 1.765 0.9869 0.0806 0.9527 1.4801 0.0798 0.5021 0.2506 -0.219 1.968 -0.4606 2.6243 0.9452 0.0366 -0.4446 -1.3862 1.0102 1.4866 0.9629 1.54 0.1419 3.1445 0.2931 -0.1899 1.3636 0.3706 2.865 -0.3203 1.2085 0.493 -0.6111 -0.5914 -0.334 -0.5398 -0.7969 -0.8552 -1.8046 -0.2221 0.4466 2.0944 -0.4427 4.6638 -0.8682 0.1457 0.4255 -0.419 -0.7318 -0.507 -0.7639 1.0084 -0.4548 -0.206 0.6103 -0.5936 1.8626 -0.9179 2.5166 0.265 -0.4631 2.2256 0.6027 -1.2418 -0.4916 -0.0591 -1.082 3.223 0.5117 -0.5904 -0.9426 1.1848 -0.3542 -0.0692 -0.9451 1.3369 -0.2397 -1.3771 -0.2649 -0.3441 1.4461 2.1204 -0.0448 0.2577 -0.1469 1.0324 0.3374 -0.5561 -0.9589 -1.3297 0.2968 -1.6194 0.0651 1.137 1.4406 -0.8268 -0.6435 -0.72 0.9423 -0.938 -1.2365 -0.4282 -0.0448 1.4 0.9357 0.1461 -0.5159 -0.5515 0.0755 -0.3624 0.0645 -0.726 -0.3243 -0.8689 4.2065 -0.1621 -0.5945 0.1189 1.624 -0.7784 -0.3253 -0.3438 -1.3003 -0.4937 -0.5277 -0.6228 0.4728 2.2078 -0.4353 -0.2032 -0.9302 -0.4885 -0.2419 -0.7866 4.7418 0.6211 -1.2339 1.3845 0.5108 -0.7222 -0.9678 0.2832 -0.0755 -1.1743 -1.0083 2.5122 0.1778 3.1969 -0.012 0.0354 2.2262 0.9093 -0.1464 0.4253 2.5207 0.2035 1.3389 1.9186 1.7137 -0.2654 2.2392 -0.3996 -1.2892 -0.4742 0.5299 2.7226 1.7458 0.0864 0.523 1.0341 0.8068 -1.7386 0.5963 3.369 1.7016 0.0006 1.0281 -0.3293 -0.8416 -0.2786 -0.4047 -0.8601 0.5637 -1.0292 -0.2981 1.1655 -0.7953 0.1703 -0.2879 -0.8701 -0.0567 1.639 0.7825 0.2416 0.5757 2.2804 0.3221 2.4918 0.8396 1.3989 0.3737 1.7044 0.0833 -0.9458 -1.1202 0.3997 0.1132 3.7591 -0.591 1.0031 3.6399 -0.2797 -0.2303 -0.3658 -0.3442 2.766 -1.012 1.3627 -0.3952 -0.0127 1.8049 0.2078 0.3837 -0.0967 -0.3174 0.0524 0.7473 0.0741 -0.5059 0.7404 0.7076 0.0418 -0.2929 0.66 2.5066 -0.3603 2.5796 3.1886 0.4369 -0.7066 0.5298 0.7503 -0.0027 -1.0712 2.4244 0.1205 0.8775 1.8649 -1.114 2.4003 0.7969 -1.6063 5.3607 0.7628 1.8041 -0.7188 0.8307 -0.5612 -1.4368 -0.9172 -0.7511 -0.1751 1.0754 2.8723 -0.4021 0.1387 -0.0876 1.5533 0.2703 0.2361 -0.5347 0.1514 0.0456 1.4433 0.0075 0.0057 -0.2996 0.7196 -0.216 -0.1382 1.0337 1.2602 -0.3885 -0.1095 -0.8055 3.0395 0.9613 0.4522 -1.0876 -1.0667 -0.1013 -0.5101 1.6176 -0.6092 0.121 -0.8504 2.9531 -1.3087 0.8213 4.5849 0.474 1.3423 -0.7672 0.219 1.128 -0.3703 -0.292 -0.4438 -1.4071 0.9035 -0.6645 3.1698 0.5511 2.2373 -0.2552 1.4558 -0.5171 1.2015 -0.6755 0.0587 0.1029 -0.1955 0.8542 -0.9634 -0.3186 6.2864 -1.828 -0.6486 0.5921 1.8538 -0.2398 0.044 -0.5976 -0.5903 1.9656 -0.3758 1.071 0.2532 0.3611 6.6428 -0.0593 -0.309 0.0046 -0.359 0.5919 1.3922 0.8665 0.0261 -1.5957 -0.4893 -0.6591 0.4746 0.1279 -1.6323 -1.6649 1.9836 4.7576 -1.6111 -0.3085 -0.8042 -0.3184 -0.2403 0.0297 0.8153 -0.0775 -0.7963 -1.5813 0.4968 -1.0368 0.0749 -0.2793 0.703 -1.2054 -1.0681 0.3515 -0.8086 -0.2892 -0.0403 -0.1817 -0.5616 -0.6448 0.5462 0.3097 0.3702 4.1225 4.1168 -0.0021 -0.1181 0.7801 -0.8373 0.5753 0.5518 0.2279 -0.6973 -0.8922 -0.3987 -0.1426 -0.9519 0.8421 -0.1653 -1.149 0.893 -0.1394 -0.8105 0.8544 0.1832 0.1675 -0.3644 0.4122 0.8291 2.4866 0.1052 -0.2387 1.5401 -0.6799 0.4203 3.0795 0.6632 -0.7551 -0.7891 -0.4355 0.1079 -0.0836 1.0853 -0.1115 1.516 -0.9256 -0.0634 -0.4802 -1.0947 -0.2691 -0.0104 0.2664 1.9216 1.3642 -0.3868 -0.839 -0.9888 -0.5746 -0.3058 -0.6229 0.0854 1.4134 -0.2058 0.0217 -0.7912 0.5648 1.1579 -0.4215 -0.4223 1.6705 -0.4771 0.6029 -0.726 1.2529 -0.8094 0.3971 0.926 -0.0212 -0.3117 -0.4644 -0.6066 -0.0809 -0.5599 -0.7708 0.1994 -0.3934 -1.0398 -1.1508 0.3718 -1.0377 0.8356 0.0788 -0.4651 2.0759 7.0309 0.7332 0.305 -0.1679 -0.1476 2.3042 135 | MAPK8IP2 (cg00083937) HEATMAP GENERIC_ASSAY LIMIT-VALUE 0.600965908700663 0.514129069512132 0.769616641690092 0.69812664900243 0.799070919493019 0.735822579583125 0.361008209097112 0.630354044620056 0.626547559612314 0.715710531319197 0.629244814371861 0.737656897529819 0.631317319529248 0.560801391326944 0.446508340566739 0.494495895449146 0.777196348486248 0.70467195003229 0.568177326882578 0.605151639161332 0.631970855102427 0.639893740824469 0.469277343052793 0.592016656230102 0.631495104286855 0.696596129116654 0.466458994811162 0.74794604636645 0.709598624518612 0.578363580171894 0.671326781721952 0.726293257054276 0.569576596385253 0.74193323660488 0.546128434149204 0.678669647839654 0.730559995413672 0.710371003703426 0.731458127750535 0.58637604815133 0.580711686284361 0.372407720942255 0.7162344613192 0.708918226072652 0.688768035781728 0.403909915566069 0.497916780961814 0.697540166283395 0.473165975877545 0.797027064221362 0.748671599388255 0.727224771974673 0.851714307076105 0.64227593712784 0.723765879663532 0.657615162546738 0.679769217879613 0.489589104745992 0.728754796012137 0.598908278266987 0.706472119769717 0.628295016599557 0.436351425611201 0.65402302268778 0.697035491533446 0.55886491964698 0.656157029013105 0.449551097511629 0.715444766145794 0.680469252810083 0.548591320895306 0.674100035582568 0.724707574212972 0.588381103700503 0.70287447438066 0.520931051526475 0.611538404216711 0.625771985027192 0.4490989766239 0.50615035171737 0.585781958448652 0.790166448272218 0.744903740075108 0.715502416344498 0.666103236109301 0.656914865661157 0.605499728438882 0.663189875245792 0.652729867834188 0.730512433681607 0.729049345207247 0.644942280999909 0.77057666674969 0.796809626785946 0.71707550219956 0.800952438376539 0.54177336048816 0.666892126187258 0.80595962375822 0.587739932003243 0.745477073731674 0.573384832702416 0.412811786664272 0.821876435090489 0.550682860324329 0.655493033217475 0.506301916655979 0.735807390895202 0.329049878982457 0.74921154901007 0.572368779945866 0.727850024166324 0.650741916488354 0.691327931411855 0.724644671400367 0.671954315142409 0.692140034926947 0.730497565361549 0.635371425454266 0.699158936911401 0.716941344903271 0.39458706239155 0.505035078381668 0.691587699331575 0.534080480568808 0.729046333499801 0.787207015814568 0.859593316508702 0.671808504121242 0.468282780395725 0.865987914459782 0.654750782902474 0.628435027309698 0.669874449386351 0.659017144564773 0.601374744150262 0.74624892150617 0.72641770693893 0.61924668662636 0.586813485793241 0.55021912913486 0.62194651738805 0.686885859842114 0.500225352797243 0.438709559417879 0.623894429259652 0.593003451616396 0.761151681932764 0.774392792872226 0.609381478902303 0.606926704189247 0.672534467820003 0.783721029238334 0.551889951873233 0.548065824256782 0.553696592205511 0.558863886582595 0.603460850546958 0.583462966002895 0.684111719481094 0.793921579388076 0.62541389042283 0.756359393664705 0.645703151843354 0.695928944741594 0.568554646170398 0.687541990504005 0.531618704022806 0.642135408644622 0.490496007615181 0.495452097396712 0.549156335475332 0.485414721396927 0.607489478783811 0.704975007121971 0.697673378890973 0.658912086149576 0.74289527891643 0.592621771962599 0.587817880021854 0.606293004365959 0.678004119826409 0.593924381809945 0.563278711966243 0.571464365810588 0.64812304140186 0.76414859250871 0.717824814365456 0.624730287872449 0.556387596991486 0.677588796576701 0.51180442005285 0.785013172312953 0.418958651065488 0.589379201153888 0.674478147258981 0.718766982133181 0.759740489212236 0.531355162779698 0.757731375949352 0.686924666846795 0.663299532017334 0.749249695860268 0.92027837971365 0.573800215142819 0.658324192058548 0.784385977387062 0.726402639836541 0.745287068264115 0.767654957104972 0.532825258547005 0.79859619960244 0.742772115908234 0.517665611744301 0.669849522112073 0.657003532971903 0.645103716866143 0.746118770816488 0.544470896801955 0.588739825456286 0.764203569129136 0.594557476244513 0.637849327432627 0.584963681914945 0.458519009228484 0.412566406261447 0.614153785537181 0.642922642402979 0.764694047031928 0.596943262560519 0.509079618937538 0.691085171423816 0.579060786164883 0.712332160340716 0.703385158372532 0.3385852109569 0.567561615321765 0.557112225588234 0.662587650610931 0.808801386118224 0.677579005911883 0.633535732940743 0.698607243621808 0.495085541825469 0.652207755721547 0.621168389365626 0.595136674731939 0.765088864553156 0.669747501874805 0.685481501840533 0.487614741888647 0.573597935914579 0.585495347358597 0.445059486002137 0.72406599842523 0.366553261012451 0.807193803799493 0.645653006696944 0.650401167294127 0.532875703590499 0.608913888129417 0.614801075988335 0.491403926770985 0.658669337471086 0.805529059459697 0.663981734011278 0.71692213778266 0.726548946142379 0.560064015721773 0.678705940161212 0.61583172674648 0.578441483972077 0.66376918541321 0.440140663260689 0.261774391509608 0.584114673159079 0.539872771742643 0.644942904373663 0.58560702100677 0.270713014763111 0.665011652581334 0.590863115395726 0.536814724884781 0.477671109612649 0.644727978018491 0.671312384074802 0.725471855610722 0.642948757824346 0.58834255247965 0.688360340689135 0.580012979033404 0.760879167325566 0.668644024435173 0.557129085609161 0.756226536917725 0.53817378019919 0.634423525702253 0.481738586723352 0.407868659408689 0.457178573070281 0.626962290078004 0.75225412031198 0.529920557922495 0.69419992679941 0.507218787328368 0.623712492857326 0.685433361339037 0.534473307325957 0.620341523759055 0.590995430881368 0.638359119879217 0.627659384451754 0.662898747102961 0.590389392135211 0.613895213566426 0.689875770870119 0.620053885204327 0.423576079825352 0.656844314839315 0.768557027999603 0.463820360385776 0.723684918627486 0.521219747036636 0.444031869464841 0.724170802021215 0.430768964143402 0.699496922896226 0.600270618086842 0.484529198220048 0.615602374167492 0.583882908263649 0.615855603280241 0.707820835977267 0.801104880490995 0.792468943196288 0.552523296343056 0.733226949304363 0.670023705481853 0.73064100990974 0.679057780494847 0.716862363484978 0.534271171716905 0.654478360412227 0.516974040129772 0.469018761250463 0.636436803557408 0.468215535018991 0.790595969475125 0.758517754063248 0.845892832577784 0.391231587842207 0.623001014892186 0.648158813537204 0.584778977795734 0.724989519481809 0.669097538326564 0.658206619180783 0.564940280190746 0.658823200800031 0.613180658748401 0.532713237352115 0.776601687300446 0.651383258234037 0.560370632806256 0.581867202647293 0.593220408981918 0.642716801435857 0.723027258536098 0.475874061770047 0.504691476705781 0.601676857164006 0.413729279607743 0.595761375666026 0.705019637961351 0.669665804339187 0.673579950835185 0.807095587779799 0.825639319195049 0.518139217929207 0.494101975266189 0.749519521935701 0.600818205491425 0.584236441911796 0.713225210867408 0.49771645359976 0.539118327479881 0.731423537718296 0.699350878951728 0.656473863189311 0.710657399520677 0.779325638388703 0.693810071427549 0.551036431637497 0.791557287062699 0.599416730786025 0.59601210137481 0.541068208216986 0.738562784752175 0.354252749559933 0.366999217135475 0.803526189738715 0.730158720792686 0.64720852271317 0.692524550779697 0.663658307989484 0.642178382892408 0.497726350670118 0.620557677608083 0.572967647989707 0.761874189187311 0.618402408377693 0.533758090122534 0.82253181257673 0.553890933546306 0.576515549409146 0.697388907048704 0.671373186435902 0.591087105061408 0.55744850655753 0.555183412296094 0.662909846824482 0.430972827342546 0.814321739535704 0.542027122449772 0.823474790532106 0.590697403224036 0.744333764413416 0.718497246027015 0.746904751243209 0.645658427399677 0.692667793008105 0.70649218368045 0.437004393485796 0.840948658240227 0.632542186093541 0.724602654590382 0.68013904948047 0.685288375221744 0.633808288583647 0.821725932296651 0.70800613858719 0.684712788905534 0.691292531035994 0.615559064103077 0.481792719121704 0.586010924155511 0.789116266129048 0.774926684718798 0.602512291884538 0.491902940626986 0.603103739846263 0.599024253867242 0.6265661131272 0.660877673989784 0.613508585585102 0.80558806989743 0.779773128825607 0.728063317001731 0.56944693532714 0.660676358385275 0.541812774680031 0.758428692555852 0.592686416524134 0.45143169275635 0.637517473406968 0.538644237726202 0.760359058184249 0.611396298465587 0.600948048326058 0.586176282809632 0.575557166928024 0.57159122513986 0.691225322094038 0.635522726010577 0.55124864657439 0.607499308896356 0.624126439174166 0.684392931339697 0.665323133351346 0.603297333608305 0.450439141496224 0.637591051713563 0.630345625068778 0.598339194738275 0.53981697348982 0.576090375185672 0.705602514394479 0.699524970650884 0.694311926342196 0.598075941064543 0.606953106958135 0.554750936727461 0.635733485600819 0.633617916004556 0.618684992459092 0.623778472407134 0.633609288317926 0.54642110622505 0.631079279204004 0.732681630567305 0.592728811697244 0.496287855914758 0.665203642263098 0.551299407128214 0.709720731852182 136 | KRAS (cg00584022) HEATMAP GENERIC_ASSAY LIMIT-VALUE 0.123185115853844 0.103182406931248 0.0845806422558687 0.0804645393662329 0.034977088701612 0.096996190112915 0.0882108260000217 0.113635599474597 0.0865376569016475 0.103583033721471 0.0905799722883777 0.117215371957878 0.0954119473534706 0.0733968758351903 0.0906353542003384 0.0447854489110525 0.116291690701832 0.072130438210447 0.0778717985495271 0.093370832851682 0.0931076869818363 0.0823848182416697 0.0703753336868792 0.0352299704770614 0.10039946781228 0.0923307971969867 0.0385719840976117 0.0950374713683037 0.100739262626034 0.0912944822417599 0.0899220097126979 0.0845128653297102 0.089203295640738 0.110933077231181 0.0455034620232907 0.0806882427208808 0.0773542910706348 0.0728192785613418 0.0965250837093418 0.0711100299719251 0.0731384175841761 0.076926703080527 0.0764887118762487 0.0534263195479155 0.0706531446624244 0.115208485599493 0.0773285077825728 0.0459289955057353 0.0915113589220388 0.0591397805220724 0.0641280382518289 0.0902504916184202 0.0971293230434413 0.0747809825022867 0.0830812598755074 0.0706946897903034 0.0973892724217645 0.085957137012786 0.0780298698872255 0.0717090000104729 0.0471898363248584 0.0735562329349018 0.0993865871942065 0.0916899774828409 0.0937327887164361 0.0731021322317995 0.0947478065748847 0.0787844308274177 0.093764338992179 0.0935400677692567 0.086385266497348 0.0423238968043723 0.0814162730642681 0.096699603925894 0.0491249451529003 0.0747847345900961 0.0875713038619985 0.04030974717638 0.105932820470082 0.0876187412326771 0.0747855597472482 0.0974705727656549 0.0862670439857038 0.0667674799838222 0.0824260922639396 0.151787820246318 0.0478614196471938 0.0736681740459007 0.0658642909204093 0.0867176175922987 0.0792825490978784 0.0536748963162595 0.0431372166084272 0.0455927906661622 0.0468502541089264 0.0909475932810275 0.0847290619558864 0.0787490774386042 0.0962418001904767 0.105577288716489 0.0861960963078529 0.0393173574051129 0.042279650472233 0.090904932894431 0.0931126579082407 0.0920339468146368 0.106344358978807 0.0885077964948721 0.0962681149886441 0.0481262904795728 0.0801897453078442 0.101136285867181 0.0915698820195618 0.112897036147687 0.114428373612847 0.153702406007554 0.0796566177769641 0.0998555018307107 0.0678529787569336 0.0769022747420904 0.0655993611286955 0.0643802010081975 0.0631505877612713 0.0879524299390759 0.0738977454689583 0.0845937393897571 0.0884290648384185 0.0470866569731903 0.0801994032987327 0.0768857597110516 0.0430299193259095 0.0920818705202252 0.0616121289769654 0.0991376586427259 0.0698580113717932 0.0805189201683621 0.115523175797291 0.073253073100198 0.0939665226458682 0.0894416472189265 0.0640885219133016 0.115332817663375 0.0882937129099267 0.0947458097629798 0.0882231762313438 0.0664265057037916 0.0900102813986313 0.0844548605777408 0.0625659215546232 0.0983058913116326 0.0843954462154327 0.105917891440275 0.114023444436249 0.0774411948662457 0.0786152479034199 0.0757790062346399 0.10786129735195 0.124743101014191 0.100692971963059 0.0781359651693704 0.0711889074419096 0.0852643186058878 0.091350662258029 0.0757325184537819 0.0764357433107217 0.0657791937018551 0.0710715428944637 0.089494678494397 0.0709656391635708 0.0728251442391713 0.0713213408575419 0.0758654679079919 0.0709287515700252 0.0617862512114959 0.0719744438364309 0.0780429175875041 0.126452864933378 0.0976753476621593 0.0801978808172105 0.090978482617862 0.0462462148800828 0.0752601647171025 0.072974518047664 0.0686782391097811 0.101627916859745 0.0827358412774888 0.0960557545666996 0.0716851335811366 0.0776906066492071 0.0796555394827119 0.100662115598775 0.0424266832086438 0.0920383939301566 0.0660697160623818 0.0833631629019701 0.0736370671550237 0.099939737226029 0.108203833838908 0.070402348392675 0.0885970584901613 0.0834279838195547 0.0881651054825657 0.0691512897592555 0.097876112835033 0.0915271215025144 0.0766351503857019 0.127807653837807 0.0884559088018236 0.0878411757588456 0.0751307448316766 0.12499005634916 0.0772509027820061 0.0766797325628868 0.0544774528655244 0.0869107160348613 0.0905650176381799 0.0882864621649958 0.0735024760586379 0.0836792233385874 0.0472847429553476 0.116162093898136 0.0799217069498459 0.0882300736850436 0.0474581926933527 0.0519754075395839 0.0926260616181763 0.0925681900030236 0.0885583719735243 0.0519102813667747 0.0736905284242115 0.0682160090595899 0.0871576307661764 0.106559249207785 0.0459914261594982 0.0882718423104216 0.0716994149559187 0.0492963247083807 0.078909406311304 0.0458986306911503 0.0372214477132983 0.13021340120956 0.0838955376904365 0.0906891911912179 0.0369196949504542 0.0842318125049461 0.0958525662605614 0.0370781165642101 0.088028572812035 0.0491431615711101 0.0681249910775729 0.0866593501959693 0.0602290338621592 0.105606323479097 0.0970262288836465 0.067560180350187 0.0953090157247186 0.0847002555163913 0.135331124057288 0.0654481061245737 0.104760315735023 0.0749456529141112 0.0903200747780399 0.105066477909899 0.0797229340439979 0.0751385737646563 0.0764984600835798 0.087604092472703 0.0655445606143782 0.069111363833016 0.0957686918955631 0.0657783798139267 0.0822394168514463 0.0741535630488389 0.0741256500238387 0.104168555073594 0.107459215106471 0.0925034762800538 0.101572114072794 0.0882878050283086 0.0871358227841227 0.0867325275595404 0.0945128407503243 0.0637809348879478 0.0774976296389508 0.0770189522146861 0.0694110394685943 0.141392954837049 0.104546093917957 0.0961273037801462 0.0800009753687741 0.0988928040430213 0.0608723217834258 0.105891269342037 0.0404813997232094 0.0978678729197293 0.0966504337050694 0.0858168105730594 0.0436786059836648 0.0657413116661903 0.0452620102795157 0.0967204938840306 0.0429512487512717 0.0635606592763005 0.0825800684714553 0.137108887050994 0.0469912514898913 0.047822907346518 0.0764170779785397 0.159976854065288 0.0829017038003521 0.0946518073409251 0.0467955919270441 0.0643110145097932 0.0774491868891092 0.0757550372803816 0.0871162787675832 0.0689079663401103 0.0517219526797769 0.0835759057618552 0.0973140206959879 0.0912562976484859 0.0813165237312387 0.0912288990776617 0.0690699053867788 0.0972067898591504 0.067312049092635 0.0930301647508239 0.0710753651831362 0.0600156650465353 0.0854980090961351 0.121003748313533 0.0432167350326845 0.0808798171913543 0.047040666297111 0.0812872073300862 0.0651564222192053 0.0961108178853201 0.0767786756261153 0.08908488197075 0.0740837819391615 0.0908812980656154 0.0874004591824394 0.0660981109254832 0.0938003177515832 0.0449477081017064 0.0916080390014365 0.04578266523045 0.0949560440013683 0.0724327501057381 0.0799566734992002 0.0936228232553159 0.0960299141782936 0.0468248851064116 0.142199128957247 0.0800985744514012 0.0631241904574502 0.081398395160092 0.0520112669051056 0.0463187540046661 0.0783870140279651 0.0753577316159542 0.0483521261761584 0.0761615506308965 0.0845893190964895 0.07606495996526 0.100610209524763 0.077224439926811 0.0782035932148878 0.0746135776120326 0.0787498452583848 0.0870279622719979 0.0704878606432293 0.0687475223553778 0.074572793851336 0.0366159569539002 0.0463212043437821 0.0846321322829645 0.0906448500440193 0.072883039772489 0.0788783152176903 0.100470016359877 0.0730002735994608 0.0704596497987952 0.0805827996794552 0.105432773961994 0.0821726629807993 0.0765594553608507 0.0796398111397453 0.0890361460051992 0.101469014898936 0.103561876795923 0.106525542860544 0.0800209524106617 0.0994675748454638 0.0816616548323221 0.0887318160934198 0.0947552040417567 0.0691951375019486 0.0458316519458527 0.0743080066442584 0.0919050510288162 0.12491707599566 0.109273818604309 0.0974983340256739 0.0803553388417722 0.114468584890264 0.0712284401148939 0.0892058865996823 0.107639727045056 0.10376232783387 0.0588108726888201 0.0745103878102798 0.0741020562225937 0.0842089844541569 0.0744751223431752 0.0672874964059691 0.0749338689074618 0.044200247774201 0.0789618753237848 0.0800109904315154 0.0906738514935192 0.0730237859889475 0.0715792887764468 0.0722439950890828 0.0781086501802602 0.0488693872788447 0.0905650903072152 0.0899139341863979 0.088219091124923 0.0980889555527728 0.0801619814407429 0.0925956893865334 0.0466631033140018 0.118709840646522 0.0446241646985428 0.0930145624241953 0.0715924572184211 0.0898107548205834 0.13453137178487 0.0965101821075332 0.0908801919781918 0.0812217556417756 0.119929827120887 0.06832654772361 0.075421272841316 0.0636487406647755 0.0690111888804273 0.101916991062652 0.0894233587590376 0.0664815609247671 0.0931858955784405 0.113950753882815 0.0745862592695644 0.0870165397265274 0.0719782841338253 0.087727397381429 0.0741300422856873 0.0966010409150713 0.0876739182245802 0.0937964360887304 0.0763479291337292 0.0812524525064953 0.0726429841970569 0.0825420200806262 0.0618873714933377 0.0932304833320646 0.125067074245339 0.0605908707267964 0.0857240182882652 0.0679211305854439 0.0777755919213726 0.068893889866697 0.0767666199474162 0.0994065376108401 0.0978079986156598 0.100371245609694 0.0666474560099871 0.0645028893234342 0.072461416360576 0.0724772099775067 0.0753403836501342 0.0659878717918688 0.0709299538220349 0.0634754843862623 0.0688133433069488 0.0590819361495179 0.0675301580201685 0.0892478172940099 0.0739050550043002 0.0780118330026077 0.084987752740888 0.0649764271598508 0.0684473198953974 0.0819421359820651 0.0710825421576738 0.095941729018427 0.0901545613459016 0.0814066610882022 0.0853239456276608 0.0833049758333343 0.0848861489750851 0.0754859048203185 0.0814194766677976 0.0730163447478739 0.102924639761319 137 | BRAF (cg03148461) HEATMAP GENERIC_ASSAY LIMIT-VALUE 0.253221532756634 0.314714448622058 0.175502326046151 0.199490038605513 0.16635472520355 0.182602923604932 0.130195145286553 0.210478907183298 0.124207825174947 0.145364027168513 0.187650814684768 0.259293137045949 0.254356324641359 0.146033487027923 0.196552728171522 0.10881878414297 0.265123196420286 0.141296704113455 0.218666369463698 0.188539070616616 0.218640403418577 0.174935249159488 0.149904512584692 0.221481317055728 0.224454187448 0.139960377141972 0.224175960358933 0.338416491564052 0.230381406696195 0.168240135358016 0.166210888869964 0.209128746309814 0.126463540504492 0.167909705901759 0.196767280208889 0.190576240945403 0.17932006000637 0.224920293871344 0.202308151591951 0.208657585484819 0.144094434165484 0.218562289456741 0.106454778235758 0.157551881228816 0.270322149217244 0.155738749951893 0.177505196106276 0.177430455450121 0.162692303220321 0.156365813957409 0.252926170677028 0.160198281570201 0.149687241637368 0.141763728336675 0.242896938629952 0.175051773143586 0.231572465900425 0.134273084119007 0.173457147701681 0.214216195779757 0.219322625124951 0.131844373278257 0.350085407219716 0.276489574118645 0.374572251133318 0.220223808297517 0.169266760570475 0.198091594754791 0.242945017921321 0.117366175984263 0.126975851768953 0.178075197913041 0.166496201944863 0.117521662489608 0.162884566230387 0.130038175314197 0.262446841466607 0.173245991446062 0.16098879823032 0.215217894076359 0.181943574844519 0.131655045768902 0.1396304154077 0.259896096528735 0.169296379146516 0.147676770873627 0.200751886239193 0.202486085024758 0.337143421034579 0.169130168692581 0.173875513635667 0.174914289808161 0.151174721509229 0.221603790176804 0.198565683631119 0.120238703575691 0.370740673580368 0.177497951028825 0.346820893027799 0.162317291896675 0.169565702573493 0.176436852255285 0.238022770246198 0.120422301435552 0.207341347659678 0.141666577911711 0.170467512398406 0.209431032900595 0.165633991215698 0.0847588396522354 0.248712756656695 0.257103319723979 0.126601630431118 0.165750000572513 0.19097335064206 0.125768706703669 0.107862013971413 0.155692311163983 0.120927952084526 0.183520559923842 0.285684202027968 0.245017467930465 0.15724730111586 0.251302341229384 0.180867900293151 0.225372807359607 0.198757857304002 0.147199526464995 0.17753924949521 0.156290230704621 0.266590677800759 0.115169252458741 0.138769252066959 0.22523774631223 0.178031859060911 0.30853147936764 0.182896084662794 0.149780819789013 0.226684308736165 0.181780797587919 0.254337793079714 0.198873053425042 0.170702785353895 0.171482287434532 0.0860013687368247 0.14406876342946 0.251770628604841 0.234484518004182 0.194975379775289 0.144912366381456 0.2773703440592 0.0959294958990511 0.183695985368024 0.279960865906659 0.210857876591017 0.157294994564862 0.169117379412743 0.217693275665658 0.166334170699928 0.186312213925009 0.220249018067294 0.146106145371818 0.151490403539163 0.174046209268172 0.126251019922374 0.274192448188021 0.169693183493258 0.135976941690873 0.258591365112599 0.182918530611673 0.116953592007768 0.33152489856704 0.170038344550677 0.251734155412928 0.22816184867764 0.180999320155093 0.247057604827632 0.148554861788004 0.153572823153834 0.166719484308276 0.147718946146406 0.208190583637234 0.145580952798628 0.205585554356715 0.152619960682022 0.149799676164619 0.180546884241362 0.153164810362954 0.209606651448226 0.10529828452765 0.137725622164239 0.123091348642086 0.226160688306632 0.187857381629084 0.150229680846714 0.181101037262381 0.418263584010498 0.265049847085212 0.140342110688994 0.180666875254742 0.189417769507335 0.184619509616235 0.334591977824321 0.234058369108077 0.220065147815567 0.130739131230528 0.13589720814442 0.330307648799936 0.194940425031904 0.151341761218369 0.207435085733396 0.120701345415437 0.175949454320529 0.074743814273818 0.166499312489961 0.162156178311454 0.258851235963662 0.22700350178386 0.172226012776862 0.148514242114742 0.170109732736734 0.294618162990093 0.187364593876771 0.170813092548802 0.16833310859328 0.135105002586127 0.127456514907191 0.286494641968816 0.134702194710245 0.136410727412447 0.180623519391628 0.187081004708931 0.157755207806688 0.173993449850177 0.143579683050172 0.143750269437501 0.196038716823366 0.217169298060262 0.189017894946593 0.118983606041996 0.128924618405482 0.119986540774201 0.166874203906811 0.22737875205801 0.171916125096071 0.14578261450802 0.173939356277874 0.220205612283155 0.240086348195276 0.238191502777362 0.150538646043797 0.227103820481619 0.266363333481412 0.218542297976368 0.269441432661691 0.177588801052404 0.178327121119996 0.262887231935238 0.227364434974452 0.213710396602528 0.209859069686383 0.260463147987622 0.159905266283767 0.126782738732716 0.125915990641358 0.237771908766514 0.127508460039067 0.301271844153389 0.22974559826055 0.129610781186173 0.232309426746063 0.222484752825666 0.160578906877154 0.467732037377646 0.113150832699916 0.236883349004916 0.152739268381656 0.128317456418936 0.137845341108201 0.156611411800319 0.189045755548917 0.13696512640914 0.366175623023709 0.181317427081966 0.144111025151738 0.131793603757614 0.136449358435531 0.231474960675668 0.14081140375371 0.183452778938807 0.198509206147969 0.183780431968053 0.139187210390902 0.113266856605515 0.151567580789919 0.21043516044666 0.13295254888133 0.169364366751292 0.173832560972914 0.24323643296329 0.125360497299115 0.150344677295132 0.176298964639445 0.168673915135728 0.180420811711263 0.170551503743666 0.137442191657147 0.143214188972806 0.136647353810384 0.143534420806434 0.135731894974168 0.123643508258312 0.169708084500656 0.254435217311824 0.138182155046052 0.198452044540343 0.204530008630113 0.266755424540184 0.186712460398861 0.141276737070598 0.130358521290347 0.217239298048482 0.177463261600638 0.100228626933942 0.21038932539387 0.130744311021189 0.222482037410745 0.150926105229055 0.22443555135016 0.137566304132782 0.201108897484415 0.204865945198198 0.203309941458097 0.159339688545137 0.136990870249769 0.198252144838528 0.180016713281124 0.165967167826595 0.143744561826662 0.206255752879247 0.172049521635197 0.145533981773722 0.153358110750441 0.194345861875206 0.222961978232879 0.124474965855199 0.209459575459551 0.176852548985059 0.145523000804007 0.2518196569851 0.17115857736268 0.139783001256555 0.093582423077438 0.190748283420413 0.165997862991525 0.177016867876186 0.189228146519743 0.118534962564642 0.193919429623894 0.160303123173229 0.134966744730805 0.131894238540567 0.155858146859687 0.109589030785387 0.143531151965362 0.300707607184018 0.231143239296746 0.135465495872284 0.157807217805375 0.178074598790166 0.173840925532411 0.177161504335567 0.19629631025903 0.159367764368091 0.176808788093235 0.19037881337344 0.130071296663717 0.176935419158872 0.227554033082569 0.12063185888196 0.217909851643902 0.240118956837343 0.180686941548343 0.159719774732041 0.250999262356147 0.251136545990875 0.219399270757268 0.319398121648928 0.299261829530632 0.255655098235546 0.175139023301327 0.185407703677817 0.188516337730884 0.286267723673146 0.188141274490881 0.158333935500447 0.215920404974642 0.242233987692319 0.170718639463572 0.155256462347575 0.18482902883311 0.387840653216429 0.169291755542586 0.15267799470473 0.147982182097953 0.0604380521621109 0.136019521912681 0.137101110616483 0.207582395801941 0.171342730637308 0.176186543454698 0.195984676572008 0.189896626417799 0.260538402662016 0.150644750915277 0.176992933244767 0.188957775283991 0.171689774807396 0.277077582549674 0.205316347479024 0.213372674035653 0.196616681370275 0.154842187138613 0.21728492163531 0.13040115862833 0.26131178172731 0.134970839431716 0.283422539132659 0.133290188380159 0.195421765565837 0.24777698646914 0.252705122533062 0.188272846736805 0.211956735771415 0.251843894288589 0.17213905551396 0.194636222114957 0.0925076751157733 0.216950822774677 0.140268497086134 0.137286492626766 0.235754817329602 0.24454355451366 0.196697746493796 0.131813943343246 0.222621477615973 0.215193717281695 0.170502779996197 0.0924370295215503 0.161874552885171 0.232052359384262 0.147274658663507 0.139521314020685 0.142391919344216 0.213922025698747 0.167854086993545 0.285594257332111 0.20834869594947 0.162275105928887 0.151524180802323 0.171024010980351 0.141006182509227 0.0884159711735544 0.298619727631793 0.250664525958854 0.132937181387957 0.202070194854462 0.160377899493715 0.11778491624762 0.261243959948054 0.152397360915554 0.204233882083344 0.131884809208935 0.15495297229422 0.166162487061366 0.095478879904715 0.158704975997094 0.142039526068437 0.15084100198927 0.164434349244448 0.194391708414534 0.184928098426564 0.102151641554759 0.162695120360197 0.223076015293831 0.171890721420873 0.20693462766731 0.162659808367077 0.127852563358744 0.195969928076319 0.191672391433231 0.189341493924862 0.166175555640827 0.137579202655474 0.108811644153095 0.176726250022531 138 | Dicipivirus HEATMAP GENERIC_ASSAY LIMIT-VALUE 1.8185390668 2.9958157746 3.1483151867 3.8482461707 3.1845768492 2.6051289983 2.8977495319 1.3608220132 4.7837371528 5.3000490773 -0.287895388 3.1926412799 2.1924062539 4.6237596621 2.0970512375 2.2858682553 3.388857917 4.0315004504 2.8395832815 2.9664760641 3.4405264435 4.161098499 3.5480676519 4.7908230928 4.5928349723 4.9102264357 4.0078422938 4.3526106412 4.4543926636 0.584098188 3.5909929451 3.5692383519 4.5750743197 3.6395692447 4.8756933309 5.2922517931 3.0510258911 1.2963188259 2.056290474 4.1535971926 1.5005348841 3.0895591183 3.2877618102 4.6832688518 3.2363300978 4.3513795427 4.93151258 3.4347446835 1.6778644348 4.2792341802 3.4317276841 3.2631308391 3.2782558637 4.6951093699 3.8533076059 4.0891277464 4.5043736351 2.9027749344 2.4913463095 2.7467323026 3.1658501913 2.3694603241 1.634602479 3.8069833661 2.4199755771 3.1258990454 0.7525231735 4.4373609588 4.2746133528 2.4204167468 3.6877213373 3.6247297843 3.2371523336 4.7919477119 4.4496712512 3.9748958698 1.2011560714 4.0903239536 3.9624351056 4.1522348914 1.6192819062 4.5829809811 3.0533925927 3.5848661018 2.5454556657 3.2613385385 3.6835625887 3.8712151279 2.8706372876 4.2096505604 1.8538281331 3.8785334122 4.045706638 3.6603394639 3.0589918652 3.8338471316 4.523588598 3.7701018626 3.8376561076 2.628414145 4.3081862591 2.0409333453 4.3435056083 5.0134088658 2.0825514084 4.4224518639 3.8527544633 4.4229762311 3.9968624935 3.3143750827 4.5742016525 4.4446391992 2.2960955917 3.1709767245 2.8405311294 1.7599117126 3.8288603452 2.8346668502 4.0892530319 4.0831112528 4.5270610134 3.7491759284 2.8276753348 3.956237767 0.3101705611 3.7763778508 3.0742954487 3.3416140916 3.7726753175 -0.785168476 4.8906248444 3.9999950081 3.2364802506 1.9004865168 3.6413790137 3.8812405067 4.1587908439 5.7740153005 3.6069812094 3.8375809802 3.6393787322 -0.486526355 2.604250618 3.041332803 1.899803275 4.4876366999 1.6552983596 3.7891286071 2.0526335971 2.9292573462 3.9158025619 2.6544207984 3.7340334939 4.6183653672 1.9825608603 2.0082314394 3.1258205128 3.6617417187 2.6193482835 3.0809371786 0.7317285535 -0.152813323 1.7819249079 3.2658888505 4.3877723206 4.1033039076 3.6800499599 4.9064716236 3.4271422363 4.1225009241 1.6477720375 2.1998793536 3.0408488544 2.6738754649 3.1193732736 2.209623371 3.5812222767 4.1872573471 4.5019062099 2.6613452057 2.9572305397 0.8758679208 3.6820302207 4.3317627871 4.5046491503 3.7988986867 4.0497336763 3.0832039668 4.2660192628 3.7027572353 3.7280660983 3.9825890428 3.3740791157 3.3316626711 3.3645857799 1.9222641444 3.5382432001 4.4894180614 3.8274884577 5.9411909906 3.5131209907 3.2565400954 5.2138635683 3.6585037093 2.3626733676 5.1508343679 3.0960883278 3.2517356862 2.0902891069 3.5202446718 3.6887043666 3.2716791788 3.0029468708 0.0203285662 3.7636374617 3.5878337402 2.3679607976 4.4320845942 2.9954139842 3.449525782 3.2961850915 2.506684605 3.6626339779 4.8557601618 3.2740666673 3.9611139521 3.9613131811 2.8376879404 3.0111340665 3.2892957448 0.3004520418 2.9971820197 3.9913317349 3.7418857388 2.9607515345 2.7438764309 -0.118588142 3.8651954501 4.4268414565 3.0412997019 3.4770475814 2.6497902543 5.0302375528 3.3995516061 3.5354266752 7.7093483348 3.3374933346 2.6844629369 2.4563676203 4.284636408 3.6555816183 3.820881231 4.1313075358 3.0032554727 2.6024484133 0.261451479 4.0093642928 3.8385502614 3.1658014848 4.0476565994 4.2130349558 4.7499553801 5.1934033445 3.9133286381 2.8968248962 3.8946042604 3.481937919 4.4712551414 3.5155015 2.1789948505 4.9674024072 4.0981877125 3.0273818423 4.5708203614 4.1369008776 4.6637520569 4.5473444249 4.1540525917 3.2888529833 4.5393639508 3.2744740557 3.4620211064 5.0380319776 4.6319246488 2.1458631323 3.7237183722 3.6118538807 4.1601766465 1.8517873588 2.5776031071 3.1017941648 4.2099069642 2.9130884056 4.1186040419 3.5496817037 2.9750526417 4.8449353229 4.2437188866 2.5790807065 4.4637089731 4.2118169588 4.7167282934 4.3501935196 3.6312636667 2.6401323925 2.6361662494 3.2076667095 3.832122995 3.8283657575 4.1597255124 3.2357375757 3.2091986427 2.7329035561 3.8644256627 3.1304375195 4.4861443994 2.1796192278 -0.584537162 4.3254349334 3.5185703994 3.1428652144 3.5052034154 2.9642783214 3.7436953376 3.2006272251 2.9734729922 1.9157695754 3.1666863796 3.7206759702 -1.003297141 3.7647719877 3.6742867315 0.8836669692 3.5959515293 4.1296634268 3.4602673428 4.6217226219 3.8086923013 2.8848180527 4.6097022374 4.2363309928 6.3315127483 4.367926181 0.2507145961 4.5893560833 3.378492364 4.0717626591 3.4866623513 4.4280388872 3.220553221 3.6310314416 2.2943452447 3.0060300935 2.9479549993 4.2876942486 4.8041734116 3.2343631244 2.8664683371 0.2714951768 2.2195090575 4.461479715 4.1161216913 4.9633121874 2.73695921 4.1775480419 2.2003875916 3.7508552908 3.0851748633 3.8404297796 0.8797670444 3.7557560999 4.3162973407 2.9081652227 4.2824926118 2.436602741 4.0608247272 4.4337884636 3.874356491 2.1087430161 3.6179345082 2.3160945147 1.8127808784 -0.288196108 3.9131791017 -0.039829035 3.6245145947 2.2170339565 3.8335811153 4.251698951 4.4897076759 4.1570204677 4.9171737126 4.7655677491 4.3806207427 4.4656420883 3.8084356307 3.7488668247 2.7104462829 2.4123069293 3.5439546485 1.7493076575 3.3255439217 1.773509759 3.2803885813 2.1123246316 3.3983942687 3.5628935239 3.8132421549 4.2937333085 -0.267440889 3.0035006773 4.5506024307 2.2081613032 3.1962922375 4.5565278132 2.4044404508 2.7480308234 4.0689196217 3.9820434183 -1.14476099 2.8062188883 1.8802510195 3.6577284497 2.6222742775 1.9958112634 2.9257430097 4.6039764247 2.8004568148 1.812669294 3.6148888208 0.1461715423 3.0449413855 4.8791045324 2.6095590427 5.1229919255 3.505734077 4.991154368 4.5269505958 3.7717647571 2.6236422057 2.9148821463 -0.131099654 -0.126550071 3.7386283117 4.0163383879 2.3464068455 3.6565032386 -0.559402549 3.0014788918 3.7588610235 3.8498848313 2.2352929608 4.0776535835 2.4713997604 1.5418389737 2.6246440542 3.5255624927 3.8579566517 3.3530013361 3.5470694794 3.4179573674 3.929158932 3.5461669941 3.6297688416 3.5107713237 2.6184588634 5.1420761111 4.1890965213 2.385963643 0.8567735093 3.9336544904 2.7342033108 2.0609076888 4.3802417583 4.0215368661 4.9498399585 3.6038231938 4.3221358978 3.7435622816 3.5964312155 4.37576095 3.974692209 2.8607821302 3.933476733 139 | -------------------------------------------------------------------------------- /oncoprint.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/pnucolab/pyoncoprint/31e6d6de78b64070a9c6c582ce3ef571b14e4c71/oncoprint.png -------------------------------------------------------------------------------- /pyoncoprint/__init__.py: -------------------------------------------------------------------------------- 1 | __version__ = "0.2.6" 2 | 3 | import numpy as np 4 | import pandas as pd 5 | 6 | from collections import defaultdict 7 | 8 | import matplotlib.pyplot as plt 9 | from matplotlib.collections import PatchCollection 10 | from matplotlib.patches import Patch, Rectangle, Polygon 11 | from matplotlib.ticker import MaxNLocator 12 | from matplotlib.lines import Line2D 13 | from matplotlib.transforms import Affine2D 14 | from matplotlib.legend_handler import HandlerLine2D 15 | from matplotlib.colors import Colormap, Normalize 16 | from matplotlib.offsetbox import OffsetImage, AnnotationBbox 17 | import matplotlib.gridspec as gridspec 18 | from mpl_toolkits.axes_grid1 import make_axes_locatable, host_subplot 19 | 20 | from numbers import Number 21 | from copy import copy 22 | 23 | 24 | def _get_text_bbox(t, ax, x=0, y=0, scale=[1, 1], fontdict=None): 25 | is_str = isinstance(t, str) 26 | if is_str: 27 | t = ax.text(x, y, t, fontdict=fontdict) 28 | bb = t.get_window_extent(ax.figure.canvas.get_renderer()).transformed(ax.transData.inverted()).transformed(Affine2D().scale(*scale)) 29 | if is_str: 30 | t.remove() 31 | return bb 32 | 33 | 34 | class OncoPrint: 35 | def __init__(self, recurrence_matrix, genes=None, samples=None, separator=","): 36 | if isinstance(recurrence_matrix, pd.DataFrame): 37 | if samples is None: 38 | samples = recurrence_matrix.columns 39 | if genes is None: 40 | genes = recurrence_matrix.index 41 | mat = recurrence_matrix.to_numpy() 42 | else: 43 | mat = recurrence_matrix 44 | 45 | if genes is None: 46 | genes = np.array(["Gene %d"%i for i in range(1, recurrence_matrix.shape[0] + 1)]) 47 | if samples is None: 48 | samples = np.array(["Sample %d"%i for i in range(1, recurrence_matrix.shape[1] + 1)]) 49 | 50 | _, uniq_idx = np.unique(genes, return_index=True) 51 | if len(uniq_idx) != len(genes): 52 | dedup_mat = [] 53 | dedup_genes = genes[np.sort(uniq_idx)] 54 | for g in dedup_genes: 55 | rows = mat[genes == g, :] 56 | joined_row = rows[0] 57 | for ridx in range(1, len(rows)): 58 | for cidx in range(len(samples)): 59 | if self._is_valid_string(joined_row[cidx]) and self._is_valid_string(rows[ridx][cidx]): 60 | joined_row[cidx] += separator + rows[ridx][cidx] 61 | elif self._is_valid_string(rows[ridx][cidx]): 62 | joined_row[cidx] = rows[ridx][cidx] 63 | dedup_mat.append(joined_row) 64 | self.mat = np.array(dedup_mat) 65 | self.genes = dedup_genes 66 | else: 67 | self.mat = mat 68 | self.genes = genes 69 | 70 | self.separator = separator 71 | self.samples = samples 72 | 73 | def _is_valid_string(self, s): 74 | return isinstance(s, str) and len(s) > 0 75 | 76 | def _sort_genes_default(self): 77 | cntmat = np.zeros_like(self.sorted_mat, dtype=int) 78 | for i in range(self.sorted_mat.shape[0]): 79 | for j in range(self.sorted_mat.shape[1]): 80 | if self._is_valid_string(self.sorted_mat[i,j]): 81 | cntmat[i,j] = len(np.unique(self.sorted_mat[i,j].split(self.separator))) 82 | 83 | sorted_indices = np.argsort(np.sum(cntmat, axis=1))[::-1] # gene order 84 | self.sorted_genes = self.genes[sorted_indices] 85 | self.sorted_mat = self.sorted_mat[sorted_indices, :] 86 | 87 | def _sort_samples_default(self, mutation_types): 88 | mutation_to_weight = {mut: i for i, mut in enumerate(mutation_types[::-1], start=1)} 89 | weighted_flipped_cntmat = np.zeros_like(self.sorted_mat, dtype=int) 90 | for i in range(self.sorted_mat.shape[0]): 91 | for j in range(self.sorted_mat.shape[1]): 92 | if self._is_valid_string(self.sorted_mat[i,j]): 93 | for mut in np.unique(self.sorted_mat[i,j].split(self.separator)): 94 | weighted_flipped_cntmat[self.sorted_mat.shape[0] - i - 1, j] += mutation_to_weight.get(mut, 0) 95 | self.sorted_sample_indices = np.lexsort(weighted_flipped_cntmat)[::-1] 96 | self.sorted_samples = self.samples[self.sorted_sample_indices] 97 | self.sorted_mat = self.sorted_mat[:, self.sorted_sample_indices] 98 | 99 | def oncoprint(self, markers, annotations={}, heatmaps={}, 100 | title="", 101 | gene_sort_method='default', 102 | sample_sort_method='default', 103 | figsize=[50, 20], 104 | topplot = True, 105 | rightplot = True, 106 | legend = True, 107 | cell_background="#dddddd", gap=0.3, 108 | ratio_template="{0:.0%}", 109 | **kwargs): 110 | 111 | if 'is_topplot' in kwargs: 112 | topplot = kwargs['is_topplot'] 113 | print("Warning: is_topplot is deprecated, use topplot instead") 114 | if 'is_rightplot' in kwargs: 115 | rightplot = kwargs['is_rightplot'] 116 | print("Warning: is_rightplot is deprecated, use rightplot instead") 117 | if 'is_legend' in kwargs: 118 | legend = kwargs['is_legend'] 119 | print("Warning: is_legend is deprecated, use legend instead") 120 | for k in kwargs: 121 | if k not in ['is_topplot', 'is_rightplot', 'is_legend']: 122 | raise TypeError("OncoPrint.oncoprint() got an unexpected keyword argument '%s'" % k) 123 | 124 | mutation_types = [b[0] for b in sorted(markers.items(), key=lambda a: a[1].get('zindex', 1))] 125 | self.sorted_mat = self.mat.copy() 126 | self.sorted_genes = self.genes.copy() 127 | self.sorted_samples = self.samples.copy() 128 | self.sorted_sample_indices = list(range(len(self.samples))) 129 | if gene_sort_method != 'unsorted': 130 | if gene_sort_method == 'default': 131 | self._sort_genes_default() 132 | else: 133 | print("Warning: gene sorting method '%s' is not supported."%gene_sort_method) 134 | if sample_sort_method != 'unsorted': 135 | if sample_sort_method == 'default': 136 | self._sort_samples_default(mutation_types) 137 | else: 138 | print("Warning: sample sorting method '%s' is not supported."%sample_sort_method) 139 | 140 | if isinstance(gap, Number): 141 | gap = np.array([gap, gap]) 142 | else: 143 | assert len(gap) == 2, "gap must be a number or a list of length 2" 144 | gap = np.array(gap) 145 | 146 | backgrounds = [] 147 | background_lengths = 1.0 - gap 148 | t_scale = Affine2D().scale(*background_lengths) 149 | patch_mutations = defaultdict(lambda: [[], []]) 150 | scatter_mutations = defaultdict(lambda: [[], []]) 151 | stacked_counts_top = np.zeros([len(mutation_types), self.sorted_mat.shape[1]]) 152 | stacked_counts_right = np.zeros([len(mutation_types), self.sorted_mat.shape[0]]) 153 | counts_left = np.zeros(self.sorted_mat.shape[0]) 154 | for i in range(self.sorted_mat.shape[0]): 155 | for j in range(self.sorted_mat.shape[1]): 156 | backgrounds.append(Rectangle(-background_lengths / 2.0 + (j, i, ), *background_lengths)) 157 | if self._is_valid_string(self.sorted_mat[i,j]): 158 | counts_left[i] += 1 159 | for mut in np.unique(self.sorted_mat[i,j].split(self.separator)): 160 | if not mut in mutation_types: 161 | print("Warning: Marker for mutation type '%s' is not defined. It will be ignored."%mut) 162 | continue 163 | stacked_counts_top[mutation_types.index(mut), j] += 1 164 | stacked_counts_right[mutation_types.index(mut), i] += 1 165 | ms = markers[mut] 166 | if isinstance(ms['marker'], str) and (ms['marker'] == 'fill' or ms['marker'] == 'rect'): 167 | patch_mutations[mut][0].append(Rectangle((0, 0), 1, 1)) 168 | patch_mutations[mut][1].append((j, i, )) 169 | elif isinstance(ms['marker'], Patch): 170 | patch_mutations[mut][0].append(copy(ms['marker'])) 171 | patch_mutations[mut][1].append((j, i, )) 172 | else: 173 | scatter_mutations[mut][0].append(j) 174 | scatter_mutations[mut][1].append(i) 175 | 176 | ax_height = self.sorted_mat.shape[0] # top to bottom 177 | heatmap_patches = [] 178 | heatmap_texts = [] 179 | extra_yticks = [] 180 | for k, v in heatmaps.items(): 181 | if len(v['heatmap']) == 0: 182 | print("Warning: heatmap (%s) is empty and will be ignored."%k) 183 | continue 184 | extra_yticks += [''] + v['heatmap'].index.tolist() 185 | heatmap_texts.append((0, ax_height + 0.2, k)) 186 | ax_height += 1 187 | if isinstance(v['cmap'], str): 188 | cmap = plt.get_cmap(v['cmap']) 189 | elif isinstance(v['cmap'], Colormap): 190 | cmap = v['cmap'] 191 | else: 192 | raise TypeError("The type of 'cmap' is not supported.") 193 | vmin = v.get('vmin', v['heatmap'].min().min()) 194 | vmax = v.get('vmax', v['heatmap'].max().max()) 195 | norm = Normalize(vmin=vmin, vmax=vmax) 196 | if isinstance(v['heatmap'], pd.DataFrame): 197 | hm = v['heatmap'].iloc[:, self.sorted_sample_indices].values 198 | elif isinstance(v['heatmap'], np.ndarray): 199 | hm = v['heatmap'][self.sorted_sample_indices] 200 | else: 201 | raise ValueError("The type of 'heatmap' should be either 'pandas.DataFrame' or 'numpy.ndarray'.") 202 | for i in range(hm.shape[0]): 203 | for j in range(hm.shape[1]): 204 | val = hm[i, j] 205 | if np.isnan(val): 206 | heatmap_patches.append(Rectangle((j - .5, ax_height - .02, ), 1, 0.04, color='grey')) 207 | else: 208 | heatmap_patches.append(Rectangle((j - .5, ax_height - .5, ), 1, 1, color=cmap(norm(val)))) 209 | #backgrounds.append(Rectangle((j - .5, ax_height - .5, ), 1, 1)) 210 | ax_height += 1 211 | ax_pc_heatmap = PatchCollection(heatmap_patches, match_original=True) 212 | 213 | flag_annot = len(annotations) > 0 214 | if flag_annot: 215 | sorted_annotations = sorted(annotations.items(), key=lambda e: annotations[e[0]].get('order')) 216 | ax_annot_yticks = [] 217 | ax_annot_patches = [] 218 | for i, (annot_type, annot_dic) in enumerate(sorted_annotations): 219 | if isinstance(annot_dic['annotations'], pd.DataFrame): 220 | annots = annot_dic['annotations'].iloc[:, self.sorted_sample_indices].values 221 | elif isinstance(annot_dic['annotations'], np.ndarray): 222 | annots = annot_dic['annotations'][self.sorted_sample_indices] 223 | else: 224 | raise ValueError("The type of annotations (" + annot_type + ") should be either 'pandas.DataFrame' or 'numpy.ndarray'.") 225 | if annots.ndim > 2: 226 | raise ValueError("The dimension of annotations (" + annot_type + ") should be less than 3.") 227 | if len(annots) == 0: 228 | print("Warning: annotations (" + annot_type + ") is empty and will be ignored.") 229 | continue 230 | if annots.ndim == 1: 231 | annots = annots[:, np.newaxis] 232 | else: 233 | annots = annots.T 234 | annot_min = 0 235 | upd = False 236 | if len(annots[0]) == 1: 237 | annot_min = np.min(np.ravel(annots)) 238 | annot_gmax = np.max(np.ravel(annots)) 239 | annot_colors = annot_dic.get('colors', annot_dic.get('color', None)) 240 | ax_annot_yticks.append(annot_type) 241 | for j, annot_col in enumerate(annots): 242 | if len(annot_col) == 1 and self._is_valid_string(annot_col[0]): 243 | annot = annot_col[0] 244 | if self._is_valid_string(annot): 245 | p = Rectangle(-background_lengths / 2.0 + (j, i, ), *background_lengths, color=annot_colors[annot], lw=0) 246 | ax_annot_patches.append(p) 247 | else: 248 | if len(annot_col) > 1: 249 | annot_max = np.sum(annot_col, dtype=float) 250 | else: 251 | annot_max = annot_gmax - annot_min 252 | if annot_max > 0: 253 | annot_bottom = 0.0 254 | for annot_idx, annot_item in zip(annot_dic['annotations'].index, annot_col): 255 | annot_height = background_lengths[1] * (annot_item - annot_min) / annot_max 256 | if len(annot_col) == 1: 257 | annot_bottom = background_lengths[1] - annot_height 258 | col = annot_colors[annot_idx] if isinstance(annot_colors, dict) else annot_colors 259 | p = Rectangle(-background_lengths / 2.0 + (j, i + annot_bottom, ), 260 | background_lengths[0], annot_height, color=col, lw=0) 261 | annot_bottom += annot_height 262 | ax_annot_patches.append(p) 263 | else: 264 | p = Rectangle(-background_lengths / 2.0 + (j, i, ), *background_lengths, color=cell_background, lw=0) 265 | ax_annot_patches.append(p) 266 | ax_annot_pc = PatchCollection(ax_annot_patches, match_original=True) 267 | 268 | f = plt.figure(figsize=figsize) 269 | ax = host_subplot(111) 270 | ax_divider = make_axes_locatable(ax) 271 | ax_xticks = range(len(self.sorted_samples)) 272 | ax_yticks = range(len(self.sorted_genes)) 273 | ax.set_xticks(ax_xticks) 274 | ax.set_xticklabels(self.sorted_samples) 275 | ax.tick_params(axis='x', rotation=90) 276 | ax.set_yticks(range(len(self.sorted_genes) + len(extra_yticks))) 277 | ax.set_yticklabels([ratio_template.format(e/float(self.mat.shape[1])) for e in counts_left] + extra_yticks) 278 | ax.tick_params(top=False, bottom=False, left=False, right=False) 279 | for spine in ax.spines.values(): 280 | spine.set_visible(False) 281 | for t in heatmap_texts: 282 | ax.text(*t) 283 | ax.add_collection(PatchCollection(backgrounds, color=cell_background, linewidth=0)) 284 | ax.add_collection(ax_pc_heatmap) 285 | legend_mut_to_patch = {} 286 | legend_mut_to_scatter = {} 287 | for mut in mutation_types: 288 | ms = markers[mut] 289 | mk = ms['marker'] 290 | if mut in patch_mutations: 291 | patches, coords = patch_mutations[mut] 292 | w, h = background_lengths * (ms.get('width', 1.0), ms.get('height', 1.0), ) 293 | pc_kwargs = {k: v for k, v in ms.items() if not k in ('marker', 'width', 'height', 'zindex', )} 294 | if isinstance(mk, str) and (mk == 'fill' or mk == 'rect'): 295 | pc_kwargs['linewidth'] = pc_kwargs.get('linewidth', 0) 296 | if legend: 297 | legend_p = copy(patches[0]) 298 | legend_mut_to_patch[mut] = (legend_p, w, h, pc_kwargs) 299 | t_scale = Affine2D().scale(w, -h) 300 | for p, (x, y) in zip(patches, coords): 301 | p.set_transform(p.get_transform() + t_scale + Affine2D().translate(x - w * 0.5, y + h * 0.5)) 302 | pc = PatchCollection(patches, **pc_kwargs) 303 | ax.add_collection(pc) 304 | elif mut in scatter_mutations: 305 | scatter_kwargs = {k: v for k, v in markers[mut].items() if k != 'zindex'} 306 | if legend: 307 | legend_mut_to_scatter[mut] = scatter_kwargs 308 | ax.scatter(*scatter_mutations[mut], **scatter_kwargs) 309 | 310 | ax2 = ax.twinx() 311 | ax2.sharey(ax) 312 | ax2.set_yticks(range(len(self.sorted_genes))) 313 | ax2.set_yticklabels(self.sorted_genes) 314 | ax2.tick_params(top=False, bottom=False, left=False, right=False) 315 | for spine in ax2.spines.values(): 316 | spine.set_visible(False) 317 | 318 | ax_annot = None 319 | ax_top = None 320 | ax_right = None 321 | ax_legend = None 322 | #ratio_gap = gap / (len(self.sorted_genes) - gap) 323 | if flag_annot: 324 | num_annots = sum([len(d['annotations']) > 0 for k, d in annotations.items()]) 325 | ratio_annot = (num_annots - gap[1]) / (len(self.sorted_genes) - gap[1]) 326 | ax_annot = ax_divider.append_axes("top", size="{0:.6%}".format(ratio_annot), pad=0.2) 327 | ax_annot.add_collection(ax_annot_pc) 328 | ax_annot.set_ylim([num_annots - 1 + background_lengths[1]/2.0, -background_lengths[1]/2.0]) 329 | ax_annot.set_yticks(range(len(ax_annot_yticks))) 330 | ax_annot.set_yticklabels(ax_annot_yticks) 331 | ax_annot.sharex(ax) 332 | ax_annot.tick_params(top=False, bottom=False, left=False, right=False, 333 | labeltop=False, labelbottom=False, labelleft=True, labelright=False) 334 | for spine in ax_annot.spines.values(): 335 | spine.set_visible(False) 336 | if topplot: 337 | ax_top = ax_divider.append_axes("top", size=1, pad=0.2) 338 | ax_top.sharex(ax) 339 | bottom = np.zeros(self.mat.shape[1]) 340 | for idx, cnts in enumerate(stacked_counts_top): 341 | col = markers[mutation_types[idx]]['color'] 342 | ax_top.bar(ax_xticks, cnts, color=col, width=background_lengths[0], bottom=bottom) 343 | bottom += cnts 344 | ax_top.yaxis.set_major_locator(MaxNLocator(integer=True)) 345 | #ax_top.set_xlim(ax_xlim) 346 | ax_top.tick_params(top=False, bottom=False, left=True, right=False, 347 | labeltop=False, labelbottom=False, labelleft=True, labelright=False) 348 | for idx, spine in enumerate(ax_top.spines.values()): 349 | if idx == 0: 350 | continue 351 | spine.set_visible(False) 352 | if rightplot: 353 | ax_right = ax_divider.append_axes("right", size=2, pad=1) 354 | ax_right.sharey(ax) 355 | left = np.zeros(self.mat.shape[0]) 356 | for idx, cnts in enumerate(stacked_counts_right): 357 | col = markers[mutation_types[idx]]['color'] 358 | ax_right.barh(ax_yticks, cnts, color=col, height=background_lengths[1], left=left) 359 | left += cnts 360 | ax_right.xaxis.set_major_locator(MaxNLocator(integer=True)) 361 | ax_right.tick_params(axis='x', rotation=90) 362 | ax_right.tick_params(top=True, bottom=False, left=False, right=False, 363 | labeltop=True, labelbottom=False, labelleft=False, labelright=False) 364 | for idx, spine in enumerate(ax_right.spines.values()): 365 | if idx == 3: 366 | continue 367 | spine.set_visible(False) 368 | 369 | ax_xlim = [-background_lengths[0]/2.0, self.mat.shape[1] - 1 + background_lengths[0]/2.0] 370 | ax_ylim = [ax_height - 1 + background_lengths[1]/2.0, -background_lengths[1]/2.0] 371 | ax.set_xlim(ax_xlim) 372 | ax.set_ylim(ax_ylim) 373 | 374 | if legend: 375 | ax_size = ax.transAxes.transform([1, 1]) / f.dpi 376 | ax_size_reduced = copy(ax_size) 377 | if rightplot: 378 | ax_size_reduced[0] -= 3 # pad + size of the plot 379 | ax_scale = ax_size / ax_size_reduced 380 | bb = _get_text_bbox(" ", ax, x=0, y=0, scale=ax_scale) 381 | tw_space = abs(bb.width) 382 | text_height = abs(bb.height) 383 | line_height = max(text_height, background_lengths[1]) 384 | text_left_offset, text_top_offset = -bb.xmin, -bb.ymax 385 | legend_items = [] 386 | pad_x, pad_y = -gap 387 | pad_x += tw_space * 5 388 | cur_x = pad_x 389 | cur_y = pad_y 390 | legend_patches = [] 391 | legend_texts = [] 392 | legend_pcs = [] 393 | legend_abs = [] 394 | legend_scatters = [] 395 | legend_yticks = [0.5, ] 396 | legend_titles = ['Genetic Alteration', ] 397 | 398 | gap_handle_to_text = tw_space * 2 399 | 400 | def add_legend_item(label, col, cur_x, cur_y, is_first, is_mut): 401 | legend_item_width = background_lengths[0] + gap_handle_to_text + abs(_get_text_bbox(label, ax, scale=ax_scale).width) 402 | if cur_x + legend_item_width > ax_xlim[1] and not is_first: 403 | cur_x = pad_x 404 | cur_y += line_height + line_height / 2.0 405 | p = Rectangle((cur_x, cur_y), *background_lengths, color=col, lw=0) 406 | #p = Rectangle((0, 0), 1, 1, color=col) 407 | #p.set_transform(Affine2D().scale(*background_lengths).translate(cur_x, cur_y)) 408 | legend_patches.append(p) 409 | if is_mut: 410 | if label in legend_mut_to_patch: 411 | p, w, h, pc_kwargs = legend_mut_to_patch[label] 412 | #p.set_transform(p.get_transform() + Affine2D().scale(w, -h).translate(cur_x, cur_y + 0.5 + h * 0.5)) 413 | p.set_transform( 414 | p.get_transform() 415 | + Affine2D().scale(w, -h) 416 | .translate(*background_lengths * 0.5 + (cur_x - 0.5 * w, cur_y + 0.5 * h))) 417 | legend_pcs.append(PatchCollection([p], **pc_kwargs)) 418 | elif label in legend_mut_to_scatter: 419 | scatter_kwargs = legend_mut_to_scatter[label] 420 | legend_scatters.append((background_lengths * 0.5 + (cur_x, cur_y, ), scatter_kwargs)) 421 | 422 | legend_texts.append((label, 423 | cur_x + text_left_offset + background_lengths[0] + gap_handle_to_text, 424 | cur_y + text_top_offset + 0.5 + text_height / 2.0)) 425 | cur_x += legend_item_width + tw_space * 10 426 | return cur_x, cur_y 427 | 428 | def add_legend_scaler(min_val, max_val, col = None, cmap = None): 429 | scaler_left_pad = 5 430 | scaler_right_pad = 2 431 | scaler_width = background_lengths[0] * 12 432 | if col is not None: 433 | p = Polygon(( 434 | (cur_x + scaler_left_pad, cur_y + background_lengths[1]), 435 | (cur_x + scaler_left_pad + scaler_width, cur_y + background_lengths[1]), 436 | (cur_x + scaler_left_pad + scaler_width, cur_y) 437 | ), color=col, lw=0) 438 | legend_patches.append(p) 439 | else: 440 | scaler_image = np.tile(cmap(np.linspace(0, 1, 256))[:, :3], (80, 1, 1)) 441 | imagebox = OffsetImage(scaler_image, zoom=0.3) 442 | ab = AnnotationBbox(imagebox, (cur_x + text_left_offset + scaler_left_pad, cur_y + background_lengths[1] * 0.5), box_alignment=(0, 0.5), frameon=False) 443 | legend_abs.append(ab) 444 | legend_texts.append(("%.2f"%min_val, 445 | cur_x + text_left_offset, 446 | cur_y + text_top_offset + 0.5 + text_height / 2.0)) 447 | legend_texts.append(("%.2f"%max_val, 448 | cur_x + text_left_offset + scaler_width + scaler_left_pad + scaler_right_pad, 449 | cur_y + text_top_offset + 0.5 + text_height / 2.0)) 450 | 451 | is_first = True 452 | for mut in mutation_types: 453 | #if is_first: 454 | # debug_x = cur_x 455 | # debug_y = cur_y 456 | cur_x, cur_y = add_legend_item(mut, cell_background, cur_x, cur_y, is_first, True) 457 | is_first = False 458 | 459 | if flag_annot: 460 | for annot_type, annot_dic in sorted_annotations: 461 | if len(annot_dic['annotations']) == 0: 462 | continue 463 | cur_x = pad_x 464 | cur_y += line_height * 2.0 465 | legend_titles.append(annot_type) 466 | legend_yticks.append(cur_y + 0.5) 467 | if 'colors' in annot_dic: 468 | is_first = True 469 | annot_colors = annot_dic['colors'] 470 | for annot_label, annot_color in sorted(annot_colors.items(), key=lambda e: e[0]): 471 | cur_x, cur_y = add_legend_item(annot_label, annot_color, cur_x, cur_y, is_first, False) 472 | is_first = False 473 | else: 474 | gmin = annot_dic['annotations'].values.ravel().min() 475 | gmax = annot_dic['annotations'].values.ravel().max() 476 | add_legend_scaler(gmin, gmax, col=annot_dic['color']) 477 | 478 | if len(heatmaps) > 0: 479 | for k, v in heatmaps.items(): 480 | if len(v['heatmap']) == 0: 481 | continue 482 | cur_x = pad_x 483 | cur_y += line_height * 2.0 484 | legend_titles.append(k) 485 | legend_yticks.append(cur_y + 0.5) 486 | vmin = v.get('vmin', v['heatmap'].min().min()) 487 | vmax = v.get('vmax', v['heatmap'].max().max()) 488 | if isinstance(v['cmap'], str): 489 | cmap = plt.get_cmap(v['cmap']) 490 | else: 491 | cmap = v['cmap'] 492 | add_legend_scaler(vmin, vmax, cmap=cmap) 493 | 494 | ax_legend_height = cur_y + 1 495 | ax_legend_height_ratio = ax_legend_height / (len(self.sorted_genes) - gap[1]) 496 | ax_legend = ax_divider.append_axes("bottom", size="{0:.6%}".format(ax_legend_height_ratio), pad=1.5) 497 | ax_legend.set_xlim(ax_xlim) 498 | ax_legend.set_ylim([ax_legend_height, 0]) 499 | 500 | #bb = _get_text_bbox("Amplification", ax) 501 | #p_bbox = Rectangle((debug_x + text_left_offset + background_lengths[0] + gap_handle_to_text, debug_y + text_top_offset + 0.5 + text_height / 2.0), abs(bb.width), -abs(bb.height)) 502 | #legend_patches.append(p_bbox) 503 | 504 | ax_legend.set_yticks(legend_yticks) 505 | ax_legend.set_yticklabels(legend_titles) 506 | ax_legend.tick_params(top=False, bottom=False, left=False, right=False, 507 | labeltop=False, labelbottom=False, labelleft=True, labelright=False) 508 | for spine in ax_legend.spines.values(): 509 | spine.set_visible(False) 510 | ax_legend.set_navigate(False) 511 | ax_legend.add_collection(PatchCollection(legend_patches, match_original=True)) 512 | for ab in legend_abs: 513 | ax_legend.add_artist(ab) 514 | for pc in legend_pcs: 515 | ax_legend.add_collection(pc) 516 | for t, x, y in legend_texts: 517 | ax_legend.text(x, y, t) 518 | for (x, y), scatter_kwargs in legend_scatters: 519 | ax_legend.scatter([x], [y], **scatter_kwargs) 520 | 521 | if title != "": 522 | ttl = f.suptitle(title) 523 | 524 | return f, (ax, ax2, ax_top, ax_annot, ax_right, ax_legend) 525 | 526 | -------------------------------------------------------------------------------- /pyproject.toml: -------------------------------------------------------------------------------- 1 | [project] 2 | name = "pyoncoprint" 3 | version = "0.2.6" 4 | description = "PyOncoPrint" 5 | readme = "README.rst" 6 | requires-python = ">=3.7" 7 | license = {text = "BSD-2-Clause"} 8 | authors = [ 9 | {name = "Jeongbin Park", email = "jeongbin.park@pusan.ac.kr"} 10 | ] 11 | classifiers = [ 12 | "Programming Language :: Python :: 3", 13 | "License :: OSI Approved :: BSD License", 14 | "Operating System :: POSIX", 15 | ] 16 | dependencies = [ 17 | "numpy", 18 | "pandas", 19 | "matplotlib", 20 | ] 21 | 22 | [project.urls] 23 | Homepage = "https://pnucolab.com" 24 | Repository = "https://github.com/pnucolab/pyoncoprint" 25 | 26 | [tool.setuptools] 27 | packages = ["pyoncoprint"] 28 | 29 | [tool.setuptools.package-data] 30 | "*" = ["*.tsv", "*.ipynb"] 31 | 32 | [build-system] 33 | requires = ["setuptools>=45", "wheel"] 34 | build-backend = "setuptools.build_meta" 35 | 36 | [dependency-groups] 37 | dev = [ 38 | "sphinx", 39 | "sphinx-rtd-theme", 40 | "sphinxcontrib-napoleon", 41 | ] 42 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | pandas 2 | numpy 3 | matplotlib 4 | --------------------------------------------------------------------------------