Dear scirpy community,
I would like to know how can I change the order of the target_col
in the ir.pl.group_abundance
function.
In my case I would like to have TRA+TRB
at the bottom of the stacked bar and no IR
at the top (the opposite to my current plot, see below)
I tried to change the categories order in my adata but it only reverts the color, not the order in the column.
order = ['no IR', 'TRA+TRB']
adata.obs['receptor_subtype'] = adata.obs['receptor_subtype'].astype('category')
adata.obs['receptor_subtype'] = adata.obs['receptor_subtype'].cat.set_categories(order, ordered=True)
Thanks a lot in advance for your help.
Llucia