1. Introducción

En este informe se analiza el desempeño comercial y financiero de Adidas mediante un análisis exploratorio de datos (EDA).

El objetivo es evaluar ventas, rentabilidad y relaciones entre variables clave para apoyar la toma de decisiones estratégicas.

Análisis Exploratorio

El análisis exploratorio permite identificar patrones, diferencias entre segmentos y relaciones entre variables clave como precio, unidades vendidas, ventas totales y utilidad operativa.

PASO 2. Cargar Base de Datos

library(readxl)
adidas <- read_excel("adidas.xlsx")

head(adidas)
## # A tibble: 6 × 11
##   distribuidor region    estado  ciudad producto precio_unidad unidades_vendidas
##   <chr>        <chr>     <chr>   <chr>  <chr>            <dbl>             <dbl>
## 1 Foot Locker  Northeast New Yo… New Y… Men's S…            50              1200
## 2 Foot Locker  Northeast New Yo… New Y… Men's A…            50              1000
## 3 Foot Locker  Northeast New Yo… New Y… Women's…            40              1000
## 4 Foot Locker  Northeast New Yo… New Y… Women's…            45               850
## 5 Foot Locker  Northeast New Yo… New Y… Men's A…            60               900
## 6 Foot Locker  Northeast New Yo… New Y… Women's…            50              1000
## # ℹ 4 more variables: ventas_total <dbl>, utilidad_operativa <dbl>,
## #   margen_operativo <dbl>, metodo_venta <chr>
str(adidas)
## tibble [9,648 × 11] (S3: tbl_df/tbl/data.frame)
##  $ distribuidor      : chr [1:9648] "Foot Locker" "Foot Locker" "Foot Locker" "Foot Locker" ...
##  $ region            : chr [1:9648] "Northeast" "Northeast" "Northeast" "Northeast" ...
##  $ estado            : chr [1:9648] "New York" "New York" "New York" "New York" ...
##  $ ciudad            : chr [1:9648] "New York" "New York" "New York" "New York" ...
##  $ producto          : chr [1:9648] "Men's Street Footwear" "Men's Athletic Footwear" "Women's Street Footwear" "Women's Athletic Footwear" ...
##  $ precio_unidad     : num [1:9648] 50 50 40 45 60 50 50 50 40 45 ...
##  $ unidades_vendidas : num [1:9648] 1200 1000 1000 850 900 1000 1250 900 950 825 ...
##  $ ventas_total      : num [1:9648] 60000 50000 40000 38250 54000 ...
##  $ utilidad_operativa: num [1:9648] 30000 15000 14000 13388 16200 ...
##  $ margen_operativo  : num [1:9648] 0.5 0.3 0.35 0.35 0.3 0.25 0.5 0.3 0.35 0.35 ...
##  $ metodo_venta      : chr [1:9648] "In-store" "In-store" "In-store" "In-store" ...
names(adidas)
##  [1] "distribuidor"       "region"             "estado"            
##  [4] "ciudad"             "producto"           "precio_unidad"     
##  [7] "unidades_vendidas"  "ventas_total"       "utilidad_operativa"
## [10] "margen_operativo"   "metodo_venta"

Indicadores de Centralidad

Se calculan indicadores para las variables clave del negocio.

# Se calculan indicadores para las variables clave del negocio.

cantidad_registros = nrow(adidas)
promedio_precio = mean(adidas$`Price per Unit`, na.rm=TRUE)
promedio_unidades = mean(adidas$`Units Sold`, na.rm=TRUE)
promedio_ventas = mean(adidas$`Total Sales`, na.rm=TRUE)
promedio_utilidad = mean(adidas$`Operating Profit`, na.rm=TRUE)
promedio_margen = mean(adidas$`Operating Margin`, na.rm=TRUE)

resultado_prom = data.frame(
  cantidad_registros,
  promedio_precio,
  promedio_unidades,
  promedio_ventas,
  promedio_utilidad,
  promedio_margen
)

resultado_prom
##   cantidad_registros promedio_precio promedio_unidades promedio_ventas
## 1               9648              NA                NA              NA
##   promedio_utilidad promedio_margen
## 1                NA              NA

Indicadores de Variabilidad (Ventas Totales)

# Tibble ya tiene columna numérica
ventas_no_na <- adidas$ventas_total[!is.na(adidas$ventas_total)]

indic_ventas <- data.frame(
  mean_ventas   = mean(ventas_no_na),
  median_ventas = median(ventas_no_na),
  min_ventas    = min(ventas_no_na),
  max_ventas    = max(ventas_no_na),
  sd_ventas     = sd(ventas_no_na)
)

indic_ventas
##   mean_ventas median_ventas min_ventas max_ventas sd_ventas
## 1    12455.08        7803.5          0      82500  12716.39

Representación Gráfica

Histograma Ventas Totales

# Crear histograma interactivo
fig <- ggplotly(
  ggplot(adidas, aes(x = ventas_total)) +
    geom_histogram(fill = "steelblue", color = "black", alpha = 0.6, bins = 30) +
    labs(
      title = "Figura 1. Distribución de Ventas Totales",
      x = "Ventas Totales",
      y = "Frecuencia"
    ) +
    theme_minimal()
)

# Mostrar la figura
fig

Interpretación

Permite identificar concentración de ventas y posibles valores atípicos.

Histograma Margen Operativo

ggplotly(
  ggplot(adidas, aes(x = margen_operativo)) +
    geom_histogram(fill = "green", color = "black", alpha = 0.6, bins = 25) +
    labs(
      title = "Figura 2. Distribución del Margen Operativo",
      x = "Margen Operativo",
      y = "Frecuencia"
    ) +
    theme_minimal()
)

Boxplot Ventas Totales

  ggplot(adidas, aes(y = ventas_total)) +
    geom_boxplot(fill = "lightblue", color = "black") +
    labs(
      title = "Figura 3. Boxplot Ventas Totales",
      y = "Ventas Totales"
    ) +
    theme_minimal()

# Ventas por Región

# Agrupar y sumar ventas por región
ventas_region <- adidas %>%
  group_by(region) %>%
  summarise(Ventas = sum(ventas_total, na.rm = TRUE))

# Crear gráfico interactivo
ggplotly(
  ggplot(ventas_region, aes(x = reorder(region, Ventas), y = Ventas)) +
    geom_bar(stat = "identity", fill = "purple") +
    coord_flip() +
    labs(
      title = "Figura 4. Ventas Totales por Región",
      x = "Región",
      y = "Ventas Totales"
    ) +
    theme_minimal()
)

Análisis Bivariado

Precio vs Unidades Vendidas

# Calcular correlación
corr <- cor(adidas$precio_unidad, adidas$unidades_vendidas, use = "complete.obs")

# Gráfico interactivo
ggplotly(
  ggplot(adidas, aes(x = precio_unidad, y = unidades_vendidas)) +
    geom_point(color = "purple", alpha = 0.7) +
    geom_smooth(method = "lm", color = "grey") +
    labs(
      title = paste("Figura 5. Precio vs Unidades Vendidas\nCorrelación:",
                    round(corr, 2)),
      x = "Precio por Unidad",
      y = "Unidades Vendidas"
    ) +
    theme_minimal()
)

#Correlación General

numericas <- adidas %>% select(where(is.numeric))
cor_matrix <- cor(numericas, use="complete.obs")
corrplot(cor_matrix, method="color", type="upper")

#Hallazgos Relevantes

#Se observan diferencias significativas en ventas por región.

#Existe relación entre ventas totales y utilidad operativa.

#El precio parece tener relación inversa con las unidades vendidas.

#Algunos segmentos presentan mayor margen operativo.

#¿Qué decisiones se pueden tomar?
#1️⃣ Estrategia de precios

#Si la correlación precio–unidades es negativa fuerte, se debe evaluar elasticidad de demanda.

#2️⃣ Priorización regional

#Invertir más en regiones con mayor margen operativo.

#3️⃣ Optimización del portafolio

#Identificar productos con alto margen y bajo volumen para estrategias promocionales.

#4️⃣ Estrategia de canal

#Fortalecer el método de venta con mayor rentabilidad.

#5️⃣ Gestión de outliers

#Analizar ventas atípicas que podrían representar oportunidades o riesgos.