I got a really dumb question to ask, I have trouble with plot() on a map from the spData package and I can't figure it out why. I would appreciate any help or direction.

so I first simplify the original us_states2163 data

# Simplifying the polygon

us_states2163$AREA = as.numeric(us_states2163$AREA)

us_states_simp2 = rmapshaper::ms_simplify(us_states2163, keep = 0.01,

keep_shapes = TRUE)

# Creates centroids on the data

plot(us_states_simp2["total_pop_10"], reset = FALSE)

plot(st_centroid(st_geometry(us_states_simp2)), add = TRUE)

so for the us_states_simp2 I can successfully show the centroids on the map, however when I try to use this same st_centroid function on a different dataset it won't show the centroids on the map properly

plot(nz["Population"], reset=FALSE)

plot(st_centroid((st_geometry(nz)), add = TRUE))