Open ccruizm opened 4 years ago
Thank you for asking!
Before answering the question, let me clarify the following points for "10x genomics data":
Hello @yuifu
Yes, the data is in BAM format and all cells are in the file, including other reads that are not used in the analysis but BAM files can be filtered for only those cells I want to analyze.
@ccruizm Thanks!
Two options:
1. If you split a BAM file into BAM files for different cells (barcodes) using some tools (e.g. https://github.com/walaj/bxtools#split), you can use Millefy right now. (For example, you have 3000 cells (barcode) in a BAM files, you will get 3000 BAM files after splitting.)
2. Currently, Millefy doesn't have native support for 10x genomics type BAM file (a BAM file with many different barcodes). So, you have to wait some time for me to make a new module to parse such file.
Thanks for your reply @yuifu.
I will give it a try. Support for 10x BAM files will be a great tool! Most of the current experiments in scRNA are performed on that platform :)
Hi, Thanks for the nice tool, but I also have some hard time figuring out how to launch it on individual cells. I've figured out that I need to split 10x bam into induvidual bam files, but what next? Should I also convert them into bigwig?
As far as I understand millefy can take bam as input, but so far I faild even to run the example dataset starting from bam:
bwfiles = Sys.glob(file.path(system.file("extdata/bam", package="millefy"), "*.bam"))
.
.
and set " isBw" to FALSE
scTrackBw <- list(path_bam_files = bwfiles, groups = groups, group_colors = color_labels, max_value = max_value, isBw=FALSE)
the plotting then through an error ( also If I'll have several K of cells how my "groups" variable suppose to look like? Is there a naming convention for individual bam files?
So if you can give me a hand on making the plot like in your original paper that would be super helpful!
Best, Eugene
@EugeneEA Eugene
could you find a way how to use multiple BAM files from two groups? thanks,
@EugeneEA Eugene
could you find a way how to use multiple BAM files from two groups? thanks,
Hi, it was some time ago, so I do not remember it for sure, but I think I converted bam to BigWig via these two commands
bedtools genomecov -bg -ibam hHPCS_"$p".bam > hHPCS_"$p".bam.bedgraph
bedGraphToBigWig "$filename" ../chrom.sizes "$filename".bw
best, Eugene
Because this issue thread has become the gathering place for discussing using Millefy to plot data from BAM files, I'm going to tag it with my contribution to that end.
I've extended the Millefy tutorial to run in MyBinder-served Jupyter/RStudio sessions right in your browser using Millefy without need to install anything or sign-in to illustrate the two main options of using BAM files:
millefyPlot
directly BAM filesmillefyPlot
It is made for running in a Jupyter notebook using an R-based kernel that is accessible upon launch. Much of it will be directly transferable to running in RStudio, see below for link to a resource leading to how you can even use the RStudio via this MyBinder-served anonymous session without installing anything anywhere.
If you want to get started using an active session to run the notebook via MyBinder, then click here and after the the Jupyter session spins up an .ipynb
file stepping through use of BAM files will open, ready to run. You can choose to kick of running all the code by selecting 'Run
' > 'Run All Cells
' or step through running each cell in turn if you are familiar with Jupyter notebooks. Click here to view the static form of this Jupyter notebook file illustrating the use of BAM files with millefyPlot
.
Additionally, I've made the Millefy 'Quick example' document and much of the Millefy tutorial document work directly in your browser in a MyBinder-served session via Jupyter or RStduio without needing to install anything or sign-in, see my 'millefy-binder' repository at GitHub for more about that and how to kick off using it. If you haven't actually used Millefy on a computer yet then I'd start there because it makes it really easy to get started.
Good day,
I would like to know whether I can use your tool to check coverage in 10x genomics data. My aim is to check the coverage in some specific chromosomes per cluster. I have tumor samples and, as many others do, I assign malignant cells to those that have CNV (based on transcriptomics data). I want to visualize and confirm that some clusters lack genes on those specific chromosomes (loss). Is it possible to use Millefy for this purpose? can I get a plot similar to the one used for the example, but instead of depicting two conditions, divide the gene coverage per cell cluster?
Thanks in advance!