DingWB / PyComplexHeatmap

PyComplexHeatmap: A Python package to plot complex heatmap (clustermap)
https://dingwb.github.io/PyComplexHeatmap/
MIT License
279 stars 30 forks source link

Adjusting width/height of heatmap? #61

Closed racng closed 8 months ago

racng commented 8 months ago

Is there a way to adjust the width and height of the heatmap? I have tried to create a figure with plt.figure(figsize=(3,5)) before calling ClusterMapPlotter to make the heatmap skinnier. However, this forces the legend to get cut off, even when I save the figure with bbox_inches='tight'.

DingWB commented 8 months ago

The width and height of the heatmap are determined by the figsize. I guess the cutoff of the legend might be caused by different dpi in plt.show, if you save the figure into pdf and open the pdf, it should be fine. You can also paste your code and I can have a better understanding and look into it.