Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprende Challenge: Data Wrangling Workflow | Section
Data Wrangling with Tidyverse in R
Sección 1. Capítulo 11
single

single

bookChallenge: Data Wrangling Workflow

Desliza para mostrar el menú

Imagine you are working with a dataset that contains information about sales transactions from a small retail shop. The data arrives in a messy form: some values are missing, column names are inconsistent, and there are duplicate rows. Your goal is to apply a complete data wrangling workflow using Tidyverse tools in R. You will need to import (simulate) the data, clean it by renaming columns and removing duplicates, transform it by creating new variables and handling missing values, and finally summarize the sales by product category to provide insights for the shop owner.

Tarea

Desliza para comenzar a programar

You are given a simulated messy dataset representing sales transactions. Your task is to apply a complete data wrangling workflow using Tidyverse functions to clean, transform, and summarize the data.

  • Rename the columns to consistent, tidy names.
  • Remove duplicate rows from the dataset.
  • Replace missing values in the sales_amount column with 0 and remove rows with missing date_sold.
  • Create a new variable sales_amount_usd by multiplying sales_amount by 2.
  • Summarize the total sales in USD by product category.

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 11
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