Reading single-cell data in R: H5AD, loom, MEX, AnnData formats | Bioinformatics for beginners

Поделиться
HTML-код
  • Опубликовано: 6 авг 2024
  • In this video, I demonstrate reading single-cell datasets retrieved from publicly available sources into a #seurat object in #R.
    I hope you find this video informative. I look forward to your comments under the comments section!
    Link to code: github.com/kpatel427/RUclipsT...
    Links to datasets used:
    1. 20k_PBMC_3p_HT_nextgem_Chromium_X_filtered_feature_bc_matrix.h5: cf.10xgenomics.com/samples/ce...
    2. 20k_PBMC_3p_HT_nextgem_Chromium_X_raw_feature_bc_matrix.tar.gz: cf.10xgenomics.com/samples/ce...
    3. adult-hem-organs-10X-bone-marrow.loom: storage.googleapis.com/broad-...
    4. adata_SS2_for_download.h5ad: cellgeni.cog.sanger.ac.uk/cvi...
    5. ependymal_cells.rds: dataverse.harvard.edu/file.xh...
    Chapters:
    0:00 Intro
    3:06 .rds format
    5:08 .hdf5 format
    7:57 .mtx format
    11:07 .loom format
    13:54 .h5ad format
    Show your support and encouragement by buying me a coffee:
    www.buymeacoffee.com/bioinfor...
    To get in touch:
    Website: bioinformagician.org/
    Github: github.com/kpatel427
    Email: khushbu_p@hotmail.com
    #bioinformagician #bioinformatics #seurat #R #genomics #beginners #tutorial #howto #omics #research #biology #ncbi #GEO #rnaseq #ngs #singlecell

Комментарии • 84

  • @tahadinc1302
    @tahadinc1302 2 года назад +9

    i love your videos, the way you explain them is also very straight forward and easy to understand. Please keep making videos and thank you

  • @OjaswinniPathak
    @OjaswinniPathak Год назад +2

    Brilliantly done video. Simply too good.

  • @user-zh7jp5wq7h
    @user-zh7jp5wq7h Год назад

    amazingggg !! thank you so much for the precise tutorial

  • @user-gg1js5kg1p
    @user-gg1js5kg1p 10 месяцев назад

    Thanks a lot for making such an informative video.

  • @tushardhyani3931
    @tushardhyani3931 2 года назад +1

    Thank you for this video !!

  • @taysaraujocamilo2313
    @taysaraujocamilo2313 10 месяцев назад

    You are excelent! Thanks

  • @saheljahangiri3453
    @saheljahangiri3453 Год назад

    like your work buddy!

  • @ChoonghoLee
    @ChoonghoLee 2 года назад +2

    very nice!!

  • @user-ih2ku8wn5i
    @user-ih2ku8wn5i Год назад

    Simply too good

  • @mahamoussa5712
    @mahamoussa5712 Год назад

    You are amazing!!!!!!

  • @user-fn6xv8gw3y
    @user-fn6xv8gw3y 6 месяцев назад

    very helpful and well explained video. Thanks a lot!! Is it possible to use the seurat object for DESeq2 analysis?

  • @nourlarifi1689
    @nourlarifi1689 Год назад

    thank you very much

  • @kokosali5423
    @kokosali5423 11 месяцев назад

    Thank you very much! I had one problem, my data are pooled under one CSV file, how can I import it in this cas. Thank you again!

  • @AyrodsGamgam
    @AyrodsGamgam Год назад

    hi, what do you do when memory is exhausted? Thanks, see error mssg below
    > seurat_loom

  • @user-tp8xb2yh7e
    @user-tp8xb2yh7e 8 месяцев назад

    nice video

  • @user-uk7uw6vc8r
    @user-uk7uw6vc8r 5 месяцев назад

    Thank you so much for your videos, they've been a huge help.
    In this case, I run into a problem that I haven't found a solution to through googling.
    I have now tried for two unrelated .h5ad files for different papers, to load them as seurat objects in R. The Convert() step works fine, but in the LoadH5Seurat() step in both cases, I get the error: "Too many values for levels provided". Do you have any advice how I can solve this?

  • @Bananalane
    @Bananalane 9 месяцев назад

    Hi, I got the Library (seuratdisk), However I can't run any scripts after that. all errors since readRDS.... What others proceudures or data downloads we have to do before following your tutorial? Thanks again!

  • @Collection_of_online_tutorials

    Can you make one video about how to create a seurat obj from txt data

  • @cr7wakk8
    @cr7wakk8 21 день назад

    many many thanks to your video and it helps me a looooottt!! however there was an error when i was reading h5ad data like this :
    Convert("GSE246613_combined_RTPDv4_scvi_celltypist.h5ad", dest = "h5seurat", overwrite = TRUE)
    seurat_anndata

  • @anamikapandey4769
    @anamikapandey4769 Год назад

    please suggest, while i am loading SeuratDisk library ,i am getting the following errors
    error: package or namespace load failed for ‘SeuratDisk’ in get(method, envir = home):
    lazy-load database '/home/gkp/R/x86_64-pc-linux-gnu-library/4.1/Seurat/R/Seurat.rdb' is corrupt
    In addition: Warning messages:
    1: In .registerS3method(fin[i, 1], fin[i, 2], fin[i, 3], fin[i, 4], :
    restarting interrupted promise evaluation
    2: In get(method, envir = home) :
    restarting interrupted promise evaluation
    3: In get(method, envir = home) : internal error -3 in R_decompress1
    please tell what should i do now?

  • @zlj8435
    @zlj8435 2 года назад +6

    Love your classes! And for .loom format, the link says: This XML file does not appear to have any style information associated with it. The document tree is shown below. Wondering how to solve this, thanks again!

    • @Bioinformagician
      @Bioinformagician  2 года назад

      Can you paste the exact error?

    • @zlj8435
      @zlj8435 2 года назад +3

      @@Bioinformagician This XML file does not appear to have any style information associated with it. The document tree is shown below.
      ExpiredToken
      The provided token has expired.
      Request signature expired at: 2021-12-28T23:03:06+00:00
      Like this. Thank you for your help!

    • @fardaddanaeefard8247
      @fardaddanaeefard8247 Год назад

      @@zlj8435 I'm facing same error. Any help on solving this issue will be a big help

    • @nathansuek2571
      @nathansuek2571 Год назад

      @@Bioinformagician does this xml file need to be reuploaded? this is such a great tutorial and would help to be able to run the data alongside

    • @mrinalsubash8358
      @mrinalsubash8358 11 месяцев назад

      @@nathansuek2571 I am getting the same error

  • @paulacohen7970
    @paulacohen7970 Год назад

    Howdy! Clinician living in a PhD world and very lost - I have some pilot scRNAseq data that was processed in to a cloupe format for 10x Loupe Browser. And now I'm just lost on how to identify the clusters and do any meaningful comparisons. Suggestions?

  • @healthnut4936
    @healthnut4936 Год назад

    Hello, I love your videos. I am new to sc analysis. I have >10 files and two condition types and they are all in .h5 format. What do I do? Do I Read10X_h5() them individually and analyze them individually? Thanks! any help would be appreciated.

    • @Bioinformagician
      @Bioinformagician  Год назад +1

      What is the goal of your analysis? Do you want to compare across conditions? If yes, then filter and remove doublets for each dataset individually and then integrate datasets by condition.

  • @Nipsoj
    @Nipsoj 2 года назад +1

    hello, thank you for the very informative video. I was wondering if we could read single cell count data into a seurat object from a .tsv file?

    • @Bioinformagician
      @Bioinformagician  2 года назад +1

      Yes, read the tsv file. Ones you have the counts into a data.frame in R, you can provide that data.frame to counts parameter in CreateSeuratObject function.
      Something like this:
      counts.df

  • @ghaishoutak4087
    @ghaishoutak4087 2 года назад +2

    im getting the following error
    > Convert( "MCA2.0_Fig1_adata.h5ad", dest = "h5seurat", overwrite = TRUE)
    Warning: Unknown file type: h5ad
    Warning: 'assay' not set, setting to 'RNA'
    Creating h5Seurat file for version 3.1.5.9900
    Adding X as data
    Adding raw/X as counts
    Error in `[[.H5File`(source, features.source) :
    An object with name var does not exist in this group

  • @hossainadamzad5907
    @hossainadamzad5907 Год назад

    Thanks a lot for this great content, i have question:what is the difference between normal matrix and "dgCMatrix" actually???

    • @Bioinformagician
      @Bioinformagician  Год назад

      dgCMatrix is basically a class of sparse numeric matrices

  • @chrisdoan3210
    @chrisdoan3210 2 года назад +2

    Thank you for a helpful video! I load 'SeuratDisk' package and I got this error: Error in library(SeuratDisk) : there is no package called ‘SeuratDisk’. Would you please tell me why?

    • @Bioinformagician
      @Bioinformagician  2 года назад

      That is because SeuratDisk is not installed. Install SeuratDisk package first, load the library before running the code. You should not be getting this error then.

  • @realdealsa
    @realdealsa Год назад

    Great content, please enlighten me. I'm working on Nanostring Geomx DSP .dcc files, I'm struggling to load them into r using the recommended code , please help

  • @priyaamadhukaran4745
    @priyaamadhukaran4745 Год назад

    Love your videos-needs more background info as beginners like me are struggling. You did show and provide link to sample data in different formats. How did you download them and where did you save them will be helpful. The black window titled inputformat _single cell 80x x 24x how do we get it? is it necessary to have the source file name coded on it for R -studio to recognize the files? I downloaded the rds file and save in my desktop and then followed all the steps in R studio from 5. but I get error msg > source("~/.active-rstudio-document")
    Error in eval(ei, envir) : object 'ependymal_cells.rds' not found. If you could provide details that would be helpful. Thanks

    • @Bioinformagician
      @Bioinformagician  Год назад

      The window titled inputformat _singleCell is the console in RStudio where you see the output of the code. The title "~/Desktop/demo/Inputformat _singleCell" is the project working directory. To get an idea of what a project working directory is, check this link out - intro2r.com/work-d.html
      You are getting an error because your R is unable to find where the file "ependymal_cells.rds" is located on your system. Since you mentioned your file is saved on Desktop, your command should look something like this -
      readRDS("~/Desktop/ependymal_cells.rds").

  • @lanternofthegreen
    @lanternofthegreen 2 года назад +1

    Is there a database to download scRNAseq files (like SRA for bulk RNAseq) or do we have to look for different company websites, etc.?

    • @Bioinformagician
      @Bioinformagician  2 года назад +1

      You can ample of single-cell data on 10X genomics platform. Apart from that, NCBI GEO also stores a lot of single-cell datasets as well.

    • @lanternofthegreen
      @lanternofthegreen 2 года назад

      @@Bioinformagician Thank you. I was trying to ask about raw data, instead of count matrices. Do scRNAseq studies produce fastq files as well or do they use different formats? If they are in fastq format, can we download them from SRA?

  • @subatsamat4899
    @subatsamat4899 11 месяцев назад

    Would you please helpe me how to install seuratdisk packages. I couldn't download it 😢

  • @namartakalia8563
    @namartakalia8563 Год назад

    hello I am biologist and trying to learn single cell analysis from scratch. could you please help let me know the necessary software to download and share their links

  • @Bananalane
    @Bananalane 9 месяцев назад

    How do I install the "seuratdisk"?

  • @mx8128
    @mx8128 2 года назад +3

    Hi, thanks for the tutorial. I have problem reading loom. it says " could not find function "Connect"". Can you help me with this, thanks a lot!

    • @Bioinformagician
      @Bioinformagician  2 года назад

      Did you load 'SeuratDisk' package before running the command? Also, what system are you using? What are your R and Rstudio versions?

    • @mx8128
      @mx8128 2 года назад +1

      @@Bioinformagician thank you for replying!! yea i didn't load 'SeuratDisk' package, now it's working!

  • @mostafaismail4253
    @mostafaismail4253 2 года назад +1

    Can you do it in scanpy ?
    1-how import single cell data from different types of files like .mtx,h5 ....?
    2- how to run the pipeline in scanpy ?

    • @Bioinformagician
      @Bioinformagician  2 года назад

      My comfort language to code in currently is R and hence I pick packages and tools that could be run using R. Nevertheless, I will surely cover these when I try my hand at python packages :)

  • @mansisingh190
    @mansisingh190 Год назад

    I am having troubles downloading the Seurat package on Mac and have tried everything, would you know how to get around this?

  • @OjaswinniPathak
    @OjaswinniPathak Год назад

    HI,
    Where do I download the SeuratDisk package from. I was able to download Seurat as it was straight forward.
    Thanks.

    • @danieladediran3228
      @danieladediran3228 Год назад

      Am not sure, is the install.package("SeuratDisk") not working or check Satija lab documentation on how to do that

  • @anamikapandey4769
    @anamikapandey4769 2 года назад

    inspite of running the given commands for uploading hdf5 file .., i am still getting the error 'file not found', even if i have checked my directory and corrected it.
    please suggest😊

    • @Bioinformagician
      @Bioinformagician  2 года назад +1

      The error suggest it cannot find the file in the path you have provided. Please ensure you have spelled the file name correctly.

    • @anamikapandey4769
      @anamikapandey4769 2 года назад

      @@Bioinformagician thank you again😀

  • @carloseduardobuss6772
    @carloseduardobuss6772 Год назад

    Hi. Could you upload the Loom file again? Please. It's not available to download. Thank you.
    Error message:
    This XML file does not appear to have any style information associated with it. The document tree is shown below.
    ExpiredToken
    The provided token has expired.
    Request signature expired at: 2021-12-28T23:03:06+00:00

  • @alpr1864
    @alpr1864 2 года назад +1

    Hey
    Although I have downloaded the right file and even unzipped the file, R gives me this. Do you know what the solution is?
    Error: Cannot find expression matrix at C:\Users\Mahdi\Downloads
    aw_feature_bc_matrix
    aw_feature_bc_matrix\matrix.mtx.gz
    >

    • @Bioinformagician
      @Bioinformagician  2 года назад

      The error means it cannot find the "matrix.mtx.gz" file in this path - "C:\Users\Mahdi\Downloads
      aw_feature_bc_matrix
      aw_feature_bc_matrix". Can you double-check your file path?

    • @alpr1864
      @alpr1864 2 года назад

      @@Bioinformagician You were right!
      Can you please help me with this problem, as well? After running the codes of MTX, I face this error!
      Error in url(description = uri) : URL scheme unsupported by this method

    • @alpr1864
      @alpr1864 2 года назад

      Solved!
      The problem was from the new version of R.
      For windows users, you can install R version 4.0.5 (2021-03-31).
      For more info:
      github.com/satijalab/seurat/issues/5687

    • @Bioinformagician
      @Bioinformagician  2 года назад

      Awesome! This will help others who are also facing the same issue. Thanks so much!

    • @alpr1864
      @alpr1864 2 года назад

      @@Bioinformagician My pleasure!

  • @cnbmonster1042
    @cnbmonster1042 Год назад

    I like your video. But .loom format data is unable to download because the download key is expired.

  • @vishnushukla7502
    @vishnushukla7502 6 месяцев назад

    Can we make umap from processed CSV file? Please help

    • @Bioinformagician
      @Bioinformagician  6 месяцев назад

      What data does your processed CSV have?

    • @vishnushukla7502
      @vishnushukla7502 6 месяцев назад

      @@Bioinformagician first column is the geneID and other 20 columns are their logFC values...1st row is the name of each cell type

    • @Bioinformagician
      @Bioinformagician  6 месяцев назад +1

      ​@@vishnushukla7502 You will need to wrangle your data and run some commands. Linking some articles that might help:
      1. cran.r-project.org/web/packages/umap/vignettes/umap.html
      2. jtr13.github.io/cc21fall1/efficient-dimension-reduction-with-umap.html
      3. datavizpyr.com/how-to-make-umap-plot-in-r/

    • @vishnushukla7502
      @vishnushukla7502 6 месяцев назад

      @@Bioinformagician thanks...now I have my processed .mtx file (barcode, feature and matrix) with me...can you tell me how make umap plot directly from .mtx file in R

    • @vishnushukla7502
      @vishnushukla7502 6 месяцев назад

      @@Bioinformagician I already made the seurat object now..thanks a lot

  • @tranphilong2229
    @tranphilong2229 3 месяца назад

    Hello, thank you for your instruction, however, this link seem to be die " adult-hem-organs-10X-bone-marrow.loom:" Could you kindly fix this?

  • @laiumiunix
    @laiumiunix 10 месяцев назад

    QUestion: I convert a h5ad into h5seurat, now Im trying to load it into rstudio, I got this error:
    Validating h5Seurat file
    Initializing RNA with data
    Adding counts for RNA
    Adding feature-level metadata for RNA
    Error in match.arg(arg = layer, choices = Layers(object = object, search = FALSE)) :
    'arg' should be one of “counts”, “data”, “scale.data

    • @laiumiunix
      @laiumiunix 10 месяцев назад

      the h5ad I got it from the gutatlas website, I know the log counts are not available in the h5ad file

  • @nayeemanushrat3174
    @nayeemanushrat3174 2 года назад +3

    Hi, very useful tutorial, thanks a lot! I have a problem loading "Seuratdisk" library. >>SeuratDisk is not currently available on CRAN>> so I tried to install it from GitHub [if (!requireNamespace("remotes", quietly = TRUE)) {
    install.packages("remotes")
    }
    remotes::install_github("mojaveazure/seurat-disk")], but it says "Permission denied" Can you help me with this, thanks a lot!

    • @Bioinformagician
      @Bioinformagician  2 года назад +1

      What system are you using?
      Can you paste in the entire console output that throws 'permission denied' error?
      Also, can you try devtools::install_github("mojaveazure/seurat-disk") instead? Thanks!

    • @nayeemanushrat3174
      @nayeemanushrat3174 2 года назад

      @@Bioinformagician Thanks for your reply, I will try and let you know soon! 😄

  • @robertlogan9733
    @robertlogan9733 2 года назад

    Come study bioinformatics with me! enc.edu/program/bioinformatics/

  • @9447452569
    @9447452569 9 месяцев назад

    for the data adult-hem-organs-10X-bone-marrow.loom it is showing like this "ExpiredTokenInvalid argument.The provided token has expired. Request signature expired at: 2021-12-28T23:03:06+00:00" Can you help me with this.