-
Notifications
You must be signed in to change notification settings - Fork 14
Description
Hola. Estoy intentando reproducir los ejemplos del Capítulo 51 Análisis electoral: de RStudio a su periódico favorito. Todo perfecto excepto el último bloque:
map_munis |> left_join(datos_winners_muns) |> mutate(convocatoria = year(convocatoria)) |> ggplot() + geom_sf(aes(fill = winner, alpha = votos_bloque_pc), size = 0.01) + scale_fill_manual(values = colors_bloques) + facet_wrap(~convocatoria, ncol = 1) + labs(title = title, caption = "Fuente: Junta de Andalucía") + coord_sf(label_graticule = "", ndiscr=0) + theme_minimal() + theme(legend.position = "none", plot.title = element_markdown(margin=margin(0,0,10,0)))
Tras correr este código, R me da este error:
Error: Invalid index: field name 'x_start' not found
Ese nombre de campo no aparece por ningún sitio y no acierto a saber donde se produce el error y porqué. Gracias por cualquier pista y felicidades por este magnífico libro.