anndata.settings#
- anndata.settings = SettingsManager( remove_unused_categories=True, check_uniqueness=True, allow_write_nullable_strings=False, use_sparse_array_on_read=False, )[source]#
This manager allows users to customize settings for the anndata package. Settings here will generally be for advanced use-cases and should be used with caution.
The following options are available:
- settings.remove_unused_categories: bool = True[source]#
Whether or not to remove unused categories with
Categorical
.
- settings.check_uniqueness: bool = True[source]#
Whether or not to check uniqueness of the
obs
indices on__init__
ofAnnData
.
- settings.allow_write_nullable_strings: bool = False[source]#
Whether or not to allow writing of
pd.arrays.StringArray
.
- settings.use_sparse_array_on_read: bool = False[source]#
Whether or not to use
scipy.sparse.sparray
as the default class when reading in data
For setting an option please use
override()
(local) or set the above attributes directly (global) i.e.,anndata.settings.my_setting = foo
. For assignment by environment variable, use the variable name in all caps withANNDATA_
as the prefix before import ofanndata
. For boolean environment variable setting, use 1 forTrue
and 0 forFalse
.