Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprende Challenge: Build a Simple Metrics Dashboard | Automating Reports and Visual Insights
Python Automation for Reports and Visual Insights
Sección 1. Capítulo 14
single

single

bookChallenge: Build a Simple Metrics Dashboard

Desliza para mostrar el menú

Tarea

Desliza para comenzar a programar

Task: Business Metrics Dashboard

Create a function print_metrics_dashboard(df) that accepts a DataFrame with sales, conversions, and visits columns and prints a formatted summary of key business metrics.

  • Calculate total sales — the sum of the sales column
  • Calculate average order value — the mean of the sales column
  • Calculate conversion rate — the sum of conversions divided by the sum of visits, multiplied by 100

The printed output must include:

  • A header line: === Metrics Dashboard ===
  • Total sales formatted as: Total Sales: $X,XXX.XX
  • Average order value formatted as: Average Order Value: $X,XXX.XX
  • Conversion rate formatted as: Conversion Rate: XX.XX%

Solución

Switch to desktopCambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
¿Todo estuvo claro?

¿Cómo podemos mejorarlo?

¡Gracias por tus comentarios!

Sección 1. Capítulo 14
single

single

Pregunte a AI

expand

Pregunte a AI

ChatGPT

Pregunte lo que quiera o pruebe una de las preguntas sugeridas para comenzar nuestra charla

some-alt