Git Product home page Git Product logo

Comments (3)

theAeon avatar theAeon commented on August 23, 2024

It seems that the objects in matrix_list are themselves lists, not matrices. What format is your data in on the filesystem?

from liger.

sdwien avatar sdwien commented on August 23, 2024

Dear Andrew,

thanks a lot for looking into it.

I checked the matrix_list object; it is a list, as expected:

class(matrix_list)
[1] "list"

I also checked the two elements of the list, and as you said, these are also recognized as lists:

class(matrix_list$PGWT)
[1] "list"
class(matrix_list$PGKO)
[1] "list"

Is this not the expected behaviour of the read10X function? In the usage of the function, it says:
"Value: List of merged matrices across data types (returns sparse matrix if only one data type detected), or nested list of matrices organized by sample if merge=F

Did I specify the input directories (sample/outs/raw_feature_bc_matrix) correctly? This is a plain Single Cell 3' v3 experiment, as far as I know.
I assume that what is supposed to be loaded is the sample/outs/raw_feature_bc_matrix/matrix.mtx.gz , correct? This is also what I see inside the loaded elements:

matrix_list$PGWT
$`Gene Expression`
32285 x 1305055 sparse Matrix of class "dgCMatrix"
   [[ suppressing 32 column names ‘AAACCCAAGAAACCAT’, ‘AAACCCAAGAAACCCG’, ‘AAACCCAAGAAACTGT’ ... ]]
   [[ suppressing 32 column names ‘AAACCCAAGAAACCAT’, ‘AAACCCAAGAAACCCG’, ‘AAACCCAAGAAACTGT’ ... ]]
                                                                                    
Xkr4          . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ......
Gm1992        . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ......
Gm19938       . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ......
Gm37381       . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ......
[...]

So maybe I'd have to use this slot of the matrix_list for createLiger:

class(matrix_list$PGWT$`Gene Expression`)
[1] "dgCMatrix"
attr(,"package")
[1] "Matrix"

I ran the following:

PG_liger <- createLiger(list(PGWT = matrix_list$PGWT$Gene Expression, PGKO = matrix_list$PGKO$Gene Expression))

However, there is an error:

Error in createLiger(list(PGWT = matrix_list$PGWT$`Gene Expression`, PGKO = matrix_list$PGKO$`Gene Expression`)) : 
  At least one cell name is repeated across datasets; please make sure all cell names
         are unique.

I believe I have seen this error in another thread here on github, so I'll read up on it there.
I would appreciate though if you could let me know if this would be the correct way to load the data or whether you have any further suggestions.

Many thanks, best, Sophia

from liger.

theAeon avatar theAeon commented on August 23, 2024

Yeah, the dgCmatrices look like exactly what you want. It appears to me that it is loading correctly and failing on validation, which is a step in the correct direction.

from liger.

Related Issues (20)

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.