All Projects → KrishnaswamyLab → Magic

KrishnaswamyLab / Magic

Licence: gpl-2.0
MAGIC (Markov Affinity-based Graph Imputation of Cells), is a method for imputing missing values restoring structure of large biological datasets.

Projects that are alternatives of or similar to Magic

Germanwordembeddings
Toolkit to obtain and preprocess german corpora, train models using word2vec (gensim) and evaluate them with generated testsets
Stars: ✭ 189 (+0%)
Mutual labels:  jupyter-notebook
Dl4mir
Deep learning for MIR
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Deep Learning Notes
My personal notes, presentations, and notebooks on everything Deep Learning.
Stars: ✭ 191 (+1.06%)
Mutual labels:  jupyter-notebook
Beginners Pytorch Deep Learning
Repository for scripts and notebooks from the book: Programming PyTorch for Deep Learning
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Pqkmeans
Fast and memory-efficient clustering
Stars: ✭ 189 (+0%)
Mutual labels:  jupyter-notebook
Bet On Sibyl
Machine Learning Model for Sport Predictions (Football, Basketball, Baseball, Hockey, Soccer & Tennis)
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Practical Time Series Analysis
Practical Time-Series Analysis, published by Packt
Stars: ✭ 188 (-0.53%)
Mutual labels:  jupyter-notebook
Feature Engineering
Stars: ✭ 191 (+1.06%)
Mutual labels:  jupyter-notebook
Hyperdash Sdk Py
Official Python SDK for Hyperdash
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Deep Learning Paper Review And Practice
꼼꼼한 딥러닝 논문 리뷰와 코드 실습
Stars: ✭ 184 (-2.65%)
Mutual labels:  jupyter-notebook
Seldon Core
An MLOps framework to package, deploy, monitor and manage thousands of production machine learning models
Stars: ✭ 2,815 (+1389.42%)
Mutual labels:  jupyter-notebook
Tianchi Diabetes Top12
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Personal
Contains Jupyter Notebooks of stuff I am working on.
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Deep Learning With Tensorflow 2 And Keras
Deep Learning with TensorFlow 2 and Keras, published by Packt
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Self driving car specialization
Assignments and notes for the Self Driving Cars course offered by University of Toronto on Coursera
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Nbinteract
Create interactive webpages from Jupyter Notebooks
Stars: ✭ 189 (+0%)
Mutual labels:  jupyter-notebook
Adversarialvariationalbayes
This repository contains the code to reproduce the core results from the paper "Adversarial Variational Bayes: Unifying Variational Autoencoders and Generative Adversarial Networks".
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Teachopencadd
TeachOpenCADD: a teaching platform for computer-aided drug design (CADD) using open source packages and data
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook
Statistical Learning Method Camp
统计学习方法训练营课程作业及答案,视频笔记在线阅读地址:https://relph1119.github.io/statistical-learning-method-camp
Stars: ✭ 191 (+1.06%)
Mutual labels:  jupyter-notebook
Cnn Re Tf
Convolutional Neural Network for Multi-label Multi-instance Relation Extraction in Tensorflow
Stars: ✭ 190 (+0.53%)
Mutual labels:  jupyter-notebook

Markov Affinity-based Graph Imputation of Cells (MAGIC)

Latest PyPI version Latest CRAN version GitHub Actions Build Read the Docs Cell Publication DOI Twitter Github Stars

Markov Affinity-based Graph Imputation of Cells (MAGIC) is an algorithm for denoising high-dimensional data most commonly applied to single-cell RNA sequencing data. MAGIC learns the manifold data, using the resultant graph to smooth the features and restore the structure of the data.

To see how MAGIC can be applied to single-cell RNA-seq, elucidating the epithelial-to-mesenchymal transition, read our publication in Cell.

David van Dijk, et al. Recovering Gene Interactions from Single-Cell Data Using Data Diffusion. 2018. Cell.

MAGIC has been implemented in Python, Matlab, and R.

To get started immediately, check out our tutorials:

Python
R


Magic reveals the interaction between Vimentin (VIM), Cadherin-1 (CDH1), and Zinc finger E-box-binding homeobox 1 (ZEB1, encoded by colors).

Table of Contents

Python

Installation

Installation with pip

To install with pip, run the following from a terminal:

pip install --user magic-impute

Installation from GitHub

To clone the repository and install manually, run the following from a terminal:

git clone git://github.com/KrishnaswamyLab/MAGIC.git
cd MAGIC/python
python setup.py install --user

Usage

Quick Start

The following code runs MAGIC on test data located in the MAGIC repository.

import magic
import pandas as pd
import matplotlib.pyplot as plt
X = pd.read_csv("MAGIC/data/test_data.csv")
magic_operator = magic.MAGIC()
X_magic = magic_operator.fit_transform(X, genes=['VIM', 'CDH1', 'ZEB1'])
plt.scatter(X_magic['VIM'], X_magic['CDH1'], c=X_magic['ZEB1'], s=1, cmap='inferno')
plt.show()
magic.plot.animate_magic(X, gene_x='VIM', gene_y='CDH1', gene_color='ZEB1', operator=magic_operator)

Tutorials

You can read the MAGIC documentation at https://magic.readthedocs.io/. We have included two tutorial notebooks on MAGIC usage and results visualization for single cell RNA-seq data.

EMT data notebook: http://nbviewer.jupyter.org/github/KrishnaswamyLab/MAGIC/blob/master/python/tutorial_notebooks/emt_tutorial.ipynb

Bone Marrow data notebook: http://nbviewer.jupyter.org/github/KrishnaswamyLab/MAGIC/blob/master/python/tutorial_notebooks/bonemarrow_tutorial.ipynb

Matlab

Instructions for the Matlab version

  1. run_magic.m -- MAGIC imputation function
  2. test_magic.m -- Shows how to run MAGIC. Also included is a function for loading 10x format data (load_10x.m)

R

Installation

To use MAGIC, you will need to install both the R and Python packages.

If python or pip are not installed, you will need to install them. We recommend Miniconda3 to install Python and pip together, or otherwise you can install pip from https://pip.pypa.io/en/stable/installing/.

Installation from CRAN

In R, run this command to install MAGIC and all dependencies:

install.packages("Rmagic")

In a terminal, run the following command to install the Python repository.

pip install --user magic-impute

Installation from GitHub

To clone the repository and install manually, run the following from a terminal:

git clone git://github.com/KrishnaswamyLab/MAGIC.git
cd MAGIC/python
python setup.py install --user
cd ../Rmagic
R CMD INSTALL .

Usage

Quick Start

After installing the package, MAGIC can be run by loading the library and calling magic():

library(Rmagic)
library(ggplot2)
data(magic_testdata)
MAGIC_data <- magic(magic_testdata, genes=c("VIM", "CDH1", "ZEB1"))
ggplot(MAGIC_data) +
  geom_point(aes(x=VIM, y=CDH1, color=ZEB1))

Tutorials

You can read the MAGIC tutorial by running help(Rmagic::magic). For a working example, see the Rmarkdown tutorials at http://htmlpreview.github.io/?https://github.com/KrishnaswamyLab/MAGIC/blob/master/Rmagic/inst/examples/bonemarrow_tutorial.html and http://htmlpreview.github.io/?https://github.com/KrishnaswamyLab/MAGIC/blob/master/Rmagic/inst/examples/emt_tutorial.html or in Rmagic/inst/examples.

Help

If you have any questions or require assistance using MAGIC, please contact us at https://krishnaswamylab.org/get-help.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].