Giter Site home page Giter Site logo

wes-lewis / milor Goto Github PK

View Code? Open in Web Editor NEW

This project forked from marionilab/milor

0.0 0.0 0.0 52.7 MB

R package implementation of Milo for testing for differential abundance in KNN graphs

Home Page: https://marionilab.github.io/miloR/

License: GNU General Public License v3.0

R 100.00%

milor's Introduction

miloR

Milo is a method for differential abundance analysis on KNN graph from single-cell datasets. For more details, read our manuscript. If you use Milo in your study, please cite Dann, E., Henderson, N.C., Teichmann, S.A. et al. Differential abundance testing on single-cell data using k-nearest neighbor graphs. Nat Biotechnol (2021).

Build Status Coverage R-CMD-check

Installation

## Milo is available from Bioconductor (preferred stable installation)
if (!requireNamespace("BiocManager", quietly = TRUE))
    install.packages("BiocManager")

BiocManager::install("miloR")

## Install development version
devtools::install_github("MarioniLab/miloR", ref="devel") 

Tutorials

  1. Basic Milo example on simulated dataset
  2. Milo example on mouse gastrulation dataset: this includes a demo for downstream analysis functions.
  3. Integrating miloR in scanpy/anndata workflow (see also milopy for a full workflow in python)

Example work flow

An example of the Milo work flow to get started:

data(sim_trajectory)
milo.meta <- sim_trajectory$meta
milo.obj <- Milo(sim_trajectory$SCE)
milo.obj

Build a graph and neighbourhoods.

milo.obj <- buildGraph(milo.obj, k=20, d=30)
milo.obj <- makeNhoods(milo.obj, k=20, d=30, refined=TRUE, prop=0.2)

Calculate distances, count cells according to an experimental design and perform DA testing.

milo.obj <- calcNhoodDistance(milo.obj, d=30)
milo.obj <- countCells(milo.obj, samples="Sample", meta.data=milo.meta)

milo.design <- as.data.frame(xtabs(~ Condition + Sample, data=milo.meta))
milo.design <- milo.design[milo.design$Freq > 0, ]
rownames(milo.design) <- milo.design$Sample
milo.design <- milo.design[colnames(nhoodCounts(milo.obj)),]


milo.res <- testNhoods(milo.obj, design=~Condition, design.df=milo.design)
head(milo.res)

Support

For any question, feature request or bug report please create a new issue in this repository.

Contributions

We welcome contributions and suggestions from the community (though we may not take them onboard if they don't align with our development roadmap - please don't be offended). Please submit the initial idea as an issue, which we will discuss and ask for refinements/clarifications. If we approve the idea, then please open a pull request onto the devel branch, from which we will begin a review process. To smooth the process, please note that code changes must be backwards compatible, and must include all relevant unit tests.

milor's People

Contributors

mikedmorgan avatar emdann avatar akluzer avatar nturaga avatar zktuong avatar petehaitch avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.