0

have the following function

def build_plot(ware_id):

    ware_name, date, stores = get_info_for_build_plot(ware_id)
    plt.style.use('seaborn')
    plt.title(ware_name)

    min_price = min([x[-1] for x in stores.values() if x[-1]])
    min_prices = []

    for key, value in stores.items():
        current_price = value[-1]
        shop = Shop(key)

        if current_price and len(date) == len(value):
            product_info = shop.name + f' • {current_price} {chr(0x1F525)}'
            alpha = 0.6

            if current_price == min_price:
                min_prices.append(product_info)
                alpha = 1

            plt.plot(date, value, 'o', linestyle='solid', label=product_info, color=shop.color, alpha=alpha)

    return customize_plot(plt, stores, min_prices)

and I can't get the emoticons to display correctly in the legend

tried to change fonts

but I got a message that it can't find the font despite the fact that I have it installed

0 Answers0