ebi-gene-expression-group / scanpy-scripts

Scripts for using scanpy
Apache License 2.0
30 stars 13 forks source link

Feature/matrixplots #64

Closed pinin4fjords closed 4 years ago

pinin4fjords commented 4 years ago

This PR adds two matrix plotting functions, producing outputs like:

matrix_leiden_leiden_k10_r0_3_LDHB_CD3D_CD3E.pdf

(using https://icb-scanpy.readthedocs-hosted.com/en/stable/api/scanpy.pl.matrixplot.html)

rggsmatrix_leiden_k10_r0_3_LDHB_CD3D_CD3E.pdf

(using https://icb-scanpy.readthedocs-hosted.com/en/stable/api/scanpy.pl.rank_genes_groups_matrixplot.html#scanpy.pl.rank_genes_groups_matrixplot)

There's been some additional reorganisation of options reflecting the analogy between rank_genes_groups_matrixplot() and rank_genes_groups_stacked_violin().

nh3 commented 4 years ago

Many thanks for the PRs @pinin4fjords! I somehow can't get over the "rgg" series of commands. They are largely the same as the non-rgg version, except for three options. A simple "--rgg" switch and a condition checking is the only thing needed to merge those the two versions together, then we can get rid of those ugly "rgg(s)" prefix to keep the command list & names short and easier to understand. What do you think?

pinin4fjords commented 4 years ago

Well, the help text would have to be a lot of 'if you passed --rgg then then you can use these options, otherwise you can use --var-names'.. yada yada yada. But yep, guess we could do it.

Any chance we could merge the existing PRs, and then I'll go back and make this change with a separate one? Promise not to run off and release with doing it ;-).

pinin4fjords commented 4 years ago

Thanks @nh3 !