scirpy.pl.spectratype
- scirpy.pl.spectratype(adata, cdr3_col=['IR_VJ_1_junction_aa'], *, color, combine_fun=<function sum>, normalize=None, viztype='bar', kde_kws=None, **kwargs)
Show the distribution of CDR3 region lengths.
`Show the distribution of CDR3 region lengths.
Ignores NaN values.
- Parameters
- adata :
dict
|AnnData
Union
[dict
,AnnData
] AnnData object to work on.
- cdr3_col :
str
|Collection
[str
]Union
[str
,Collection
[str
]] (default:['IR_VJ_1_junction_aa']
) Column(s) containing CDR3 lengths.
- color :
str
Color by this column from
obs
. E.g. sample or diagnosis- combine_fun :
Callable
(default:<function sum at 0x00000277B4191670>
) A function definining how the
cdr3_col
columns should be merged, in case multiple ones were specified. (e.g. sum, mean, median, etc).- normalize :
None
|str
|bool
Union
[None
,str
,bool
] (default:None
) If True, compute fractions of abundances relative to the
cdr3_col
column rather than reporting abosolute numbers. Alternatively, the name of a column containing a categorical variable can be provided according to which the values will be normalized.- viztype : {‘bar’, ‘line’, ‘curve’}
Literal
[‘bar’, ‘line’, ‘curve’] (default:'bar'
) Type of plot to produce.
- **kwargs
Additional parameters passed to the base plotting function
- adata :
- Return type
- Returns
Axes object