openproblems-bio / website

Website hosted at https://openproblems.bio
Creative Commons Attribution 4.0 International
3 stars 7 forks source link

document that adata.X is None in v2 docs #256

Closed scottgigante-immunai closed 1 year ago

scottgigante-immunai commented 1 year ago

Developing new methods is confusing for anyone who has worked with anndata before, as typically you would expect that adata.X would not be None. At the very least this needs to be documented. Partially addresses https://github.com/openproblems-bio/openproblems-v2/issues/120

rcannood commented 1 year ago

The thing is that the AnnData format depends on what's defined in the api/comp_method.yml spec. So in the documentation I can't specify which slots are going to be there other than checking out the contents of this file, reading in the example datataset and printing it out, or building a per-task reference documentation. WDYT?

scottgigante-immunai commented 1 year ago

In that case I would just require that X be set? Seems more straightforward and in line with standard use of AnnData objects. We could consult with scanpy folks if you disagree but it seems pretty reasonable to assert that adata.X is defined.

rcannood commented 1 year ago

In #261 I documented that X is undefined and instead layers are used. This notation is used to make it more explicit what the matrices represent.