Metaphlan4 error with hclust2.py

Hello,
I’m trying to analyse my merged abundance table with hclust2.py and get the following errors. Could you please advise on what I might be doing wrong please?
Thanks.

/home/plzrja/miniconda3/bin/hclust2.py -i merged_abundance_table.txt -o HMP.sqrt_scale.png --skip_rows 1 --ftop 50 --f_dist_f correlation --s_dist_f braycurtis --cell_aspect_ratio 9 -s --fperc 99 --flabel_size 4 --metadata_rows 2,3,4 --legend_file HMP.sqrt_scale.legend.png --max_flabel_len 100 --metadata_height 0.075 --minv 0.01 --no_slabels --dpi 300 --slinkage complete
/home/plzrja/miniconda3/bin/hclust2.py:588: MatplotlibDeprecationWarning: You are modifying the state of a globally registered colormap. This has been deprecated since 3.3 and in 3.6, you will not be able to modify a registered colormap in-place. To remove this warning, you can make a copy of the colormap first. cmap = mpl.cm.get_cmap(“bbcry”).copy()
cm.set_under( bottom_col )
/home/plzrja/miniconda3/bin/hclust2.py:594: MatplotlibDeprecationWarning: You are modifying the state of a globally registered colormap. This has been deprecated since 3.3 and in 3.6, you will not be able to modify a registered colormap in-place. To remove this warning, you can make a copy of the colormap first. cmap = mpl.cm.get_cmap(“bbcry”).copy()
cm.set_over( top_col )
/home/plzrja/miniconda3/bin/hclust2.py:678: MatplotlibDeprecationWarning: Passing parameters norm and vmin/vmax simultaneously is deprecated since 3.3 and will become an error two minor releases later. Please pass vmin/vmax directly to the norm when creating it.
im = ax_hm.imshow( self.numpy_matrix, #origin=‘lower’,
Traceback (most recent call last):
File “/home/plzrja/miniconda3/bin/hclust2.py”, line 825, in
hclust2_main()
File “/home/plzrja/miniconda3/bin/hclust2.py”, line 822, in hclust2_main
hm.draw()
File “/home/plzrja/miniconda3/bin/hclust2.py”, line 708, in draw
cbar = fig.colorbar(im, ax_cm, orientation = ‘horizontal’, spacing=‘proportional’ if self.args.sqrt_scale else ‘uniform’ ) # , format = ticker.LogFormatterMathtext() )
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/figure.py”, line 1176, in colorbar
cb = cbar.Colorbar(cax, mappable, **cb_kw)
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/colorbar.py”, line 1197, in init
super().init(ax, **kwargs)
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/_api/deprecation.py”, line 471, in wrapper
return func(*args, **kwargs)
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/colorbar.py”, line 511, in init
self.draw_all()
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/colorbar.py”, line 528, in draw_all
self._process_values()
File “/home/plzrja/miniconda3/lib/python3.9/site-packages/matplotlib/colorbar.py”, line 962, in _process_values
b = self.norm.inverse(self._uniform_y(self.cmap.N + 1))
File “/home/plzrja/miniconda3/bin/hclust2.py”, line 74, in inverse
if matplotlib.cbook.iterable(value):
AttributeError: module ‘matplotlib.cbook’ has no attribute ‘iterable’

It seems your matplotlib version is in conflict with the version needed to run hclust2.py. I would recommend you to downgrade the matplotlib version to 2.0.0, here an example how to do it:
$ pip install seaborn==0.8.1 matplotlib==2.0.0