Python (Glitch) & 'plotly.express' library
|
10-14-2023, 03:02 PM
Post: #1
|
|||
|
|||
Python (Glitch) & 'plotly.express' library
Hello,
I'm trying to understand Python and more particularly the plotly.express library. For different reasons, I'm using Glitch to run the program. The program uses a CSV file called 'sales.csv'. To simplify, let's say that this file has 3 columns (actually 5): → 'product' (A, B or C) → 'price' → 'qtty' (quantity) With the following code, a HTML file is generated and, by launching it, I obtain a graphic (a pie): PHP Code: import plotly.express as px Now I want to get the sales amount (price * quantity) for each product, but I don't know how to handle the "price * quantity" multiplication with plotly.express (or any other calculation). I couldn't find an answer on the Internet. Does anyone know this and can explain it to me? Thanks for having read me. Bruno Sanyo CZ-0124 ⋅ TI-57 ⋅ HP-15C ⋅ Canon X-07 + XP-140 Monitor Card ⋅ HP-41CX ⋅ HP-28S ⋅ HP-50G ⋅ HP-50G |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
Python (Glitch) & 'plotly.express' library - FLISZT - 10-14-2023 03:02 PM
RE: Python (Glitch) & 'plotly.express' library - rprosperi - 10-14-2023, 03:58 PM
RE: Python (Glitch) & 'plotly.express' library - FLISZT - 10-14-2023, 04:36 PM
RE: Python (Glitch) & 'plotly.express' library - drbarnack - 10-14-2023, 05:38 PM
RE: Python (Glitch) & 'plotly.express' library - FLISZT - 10-14-2023, 06:17 PM
|
User(s) browsing this thread: 1 Guest(s)