def pheatmap(data, length, col_cluster=True, xticklabels=True, yticklabels=True, color=None, name=None, args=None):
    data = z_score(data, axis=args.z_score)
    if (len(data.columns) > 30):
        xticklabels = False
    if (len(data) > 80):
        yticklabels = False
    (vmin, vmax) = data.unstack().quantile([0.05, 0.95])
    if (args.z_score == 3):
        (vmin, vmax) = (0, 4)
    re = sns.clustermap(data, cmap=args.cmp, row_cluster=True, method=args.cluster_method, col_cluster=col_cluster, figsize=(13, 10), xticklabels=True, yticklabels=yticklabels, vmin=vmin, vmax=vmax, col_colors=color)
    re.ax_heatmap.set_xticklabels(re.ax_heatmap.xaxis.get_majorticklabels(), rotation=90)
    re.ax_heatmap.set_yticklabels(re.ax_heatmap.yaxis.get_majorticklabels(), rotation=0)
    if (col_cluster == False):
        for (group, number) in length.items():
            re.ax_col_colors.text(((((number[0] + number[1]) / 2) + 1.5) - (len(group) / 2)), 1.2, group, size=30)
        re.savefig(((name + '.') + args.save))
    else:
        re.savefig(((name + '_col_cluster.') + args.save))
    plt.close()
def pheatmap(data, length, col_cluster=True, xticklabels=True, yticklabels=True, color=None, name=None, args=None):
    data = z_score(data, axis=args.z_score)
    if (len(data.columns) > 30):
        xticklabels = False
    if (len(data) > 80):
        yticklabels = False
    (vmin, vmax) = data.unstack().quantile([0.05, 0.95])
    if (args.z_score == 3):
        (vmin, vmax) = (0, 4)
    re = sns.clustermap(data, cmap=args.cmp, row_cluster=True, method=args.cluster_method, col_cluster=col_cluster, figsize=(13, 10), xticklabels=True, yticklabels=yticklabels, vmin=vmin, vmax=vmax, col_colors=color)
    re.ax_heatmap.set_xticklabels(re.ax_heatmap.xaxis.get_majorticklabels(), rotation=90)
    re.ax_heatmap.set_yticklabels(re.ax_heatmap.yaxis.get_majorticklabels(), rotation=0)
    if (col_cluster == False):
        for (group, number) in length.items():
            re.ax_col_colors.text(((((number[0] + number[1]) / 2) + 1.5) - (len(group) / 2)), 1.2, group, size=30)
        re.savefig(((name + '.') + args.save))
    else:
        re.savefig(((name + '_col_cluster.') + args.save))
    plt.close()