def plot_pie(customer): data = Data() df = data.get_product_customer().groupby('CUST_NAME') df_cust = df.get_group(customer) chart = Chart() return chart.plot_pie(df_cust, customer)
dcc.Dropdown(id="map_feature", options=[{ "label": x, "value": x } for x in data.get_columns_map()], value="TOTAL PRICE") ]) # products input products_input = dbc.FormGroup([ dcc.Dropdown( id="product_name", options=[{ "label": x, "value": x } for x in data.get_product_customer().PROD_NAME.unique().tolist()], placeholder="Select a Product") ]) plots_top_top = html.Div([ dbc.FormGroup([ dcc.Dropdown(id="top_top", options=[{ "label": x, "value": x } for x in data.get_columns_map()], placeholder="Top Customers By") ]) ]) plots_worst_worst = html.Div([