I've been trying to run through this tutorial (https://bedapub.github.io/besca/tutorials/scRNAseq_tutorial.html) for the past day and constantly get an error after running this portion:
bc.pl.kp_genes(adata, min_genes=min_genes, ax = ax1)
The error is the following:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/opt/miniconda3/lib/python3.9/site-packages/besca/pl/_filter_threshold_plots.py", line 57, in kp_genes
ax.set_yscale("log", basey=10)
File "/opt/miniconda3/lib/python3.9/site-packages/matplotlib/axes/_base.py", line 4108, in set_yscale
ax.yaxis._set_scale(value, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/matplotlib/axis.py", line 761, in _set_scale
self._scale = mscale.scale_factory(value, self, **kwargs)
File "/opt/miniconda3/lib/python3.9/site-packages/matplotlib/scale.py", line 597, in scale_factory
return scale_cls(axis, **kwargs)
TypeError: __init__() got an unexpected keyword argument 'basey'
Anyone have any thoughts? I've uninstalled and installed matplotlib to make sure its updated but that doesn't seem to have done anything either.
Would appreciate any help! And thank you in advance I'm a beginner!
I had a similar problem when I tried to scale the y-axis of my plot logarithmically. Thereby the base should be 2. I had success when I tried base=2 instead of basey=2.
plt.yscale("log",base=2)
This should also work with the latest version of matplotlib.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With