For my Master thesis i work with trees. I got 36 trees, one tree is my main tree, ever further tree i got the distance and the azimut° in relation to the main tree.
When in now plot all the trees, to show where they grow in the relation to the main tree, the full circle of the plot seems to only have ~330°.
You can see it easily by looking at the labels (which are supposed to be the directions of the sky).
It seems to me that it is because of the tree nr.24, because it has the highest azimut° with 329.4°.
there is no error or any other problem.
How do i fix the plot to be a full circle with 360° ?
Code
library(ggplot2)
pie <- ggplot(Baumdaten, aes(x = distanz, label = Nr))
pie + coord_polar(theta = "y", start = 0) +
geom_point(mapping = aes(distanz,azimut),
size = 15*Baumdaten$baumumfang/max(Baumdaten$baumumfang),
col = "deepskyblue") +
geom_text(y = Baumdaten$azimut, size = 5) +
theme_bw(base_size = 15) +
theme(axis.text.x = element_text(angle=0, vjust = 1, hjust=1, size = 15) )+
# axis.line.y.left = element_line(),
# axis.ticks.y.left = element_line()
# ) +
labs(x = "Distanz zum Zentralbaum [m]", y = NULL) +
scale_y_continuous(breaks=c(0,45,90,135,180,225,270,315),
labels=c("N","NO","O","SO","S","SW","W","NW") ) +
ggtitle("") +
theme(plot.title = element_text(hjust = 0.5))
Data
Baumdaten <- structure(list(Nr = 1:36, baumumfang = c(166.42, 124.03, 117.75,
130.31, 125.6, 153.86, 164.85, 147.58, 122.46, 109.9, 141.3,
130.31, 125.6, 122.46, 114.61, 122.46, 139.73, 152.29, 103.62,
119.32, 117.75, 133.45, 111.47, 117.75, 131.88, 166.42, 141.3,
106.76, 103.62, 113.04, 150.72, 166.42, 153.86, 139.73, 125.6,
122.46), baumhoehe = c(NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA, NA,
NA, NA, NA, NA, NA, NA, NA, NA, NA, NA), distanz = c(0, 3, 5.2,
5, 10, 12.2, 13, 10.8, 13.8, 14.8, 17.7, 27.1, 27, 35, 14.6,
24, 12.1, 18.4, 17.3, 26, 25, 29.5, 31.4, 34.1, 37, 46, 46, 43,
48, 42, 41, 34.4, 25, 24, 20.5, 14.1), azimut = c(0, 113, 261.3,
30.1, 255.3, 222.6, 180.9, 148, 133.2, 112.6, 117.1, 112, 103.3,
101.4, 144.7, 119.4, 288.3, 286.5, 317.2, 303.3, 327.1, 314.7,
325.3, 329.4, 323.5, 325.8, 318.4, 307.6, 301.7, 292, 288.5,
286.5, 284.4, 277.3, 262.9, 242.8), Kronenverlichtung = c(40L,
30L, 40L, 98L, 30L, 50L, 95L, 40L, 30L, 40L, 70L, 40L, 40L, 100L,
40L, 60L, 40L, 95L, 100L, 20L, 20L, 5L, 40L, 100L, 15L, 100L,
90L, 40L, 60L, 100L, 40L, 70L, 50L, 50L, 30L, 80L), Vergilbung = c(0L,
0L, 0L, 0L, 0L, 0L, 3L, 1L, 0L, 0L, 1L, 2L, 0L, 0L, 1L, 0L, 1L,
4L, 0L, 0L, 0L, 0L, 3L, 0L, 0L, 0L, 0L, 0L, 3L, 0L, 0L, 1L, 0L,
0L, 0L, 3L), durchmesser = c(53, 39.5, 37.5, 41.5, 40, 49, 52.5,
47, 39, 35, 45, 41.5, 40, 39, 36.5, 39, 44.5, 48.5, 33, 38, 37.5,
42.5, 35.5, 37.5, 42, 53, 45, 34, 33, 36, 48, 53, 49, 44.5, 40,
39)), row.names = c(NA, -36L), class = "data.frame")
The 330° circle: