I have marked point pattern data data. I want to plot the marked point pattern where the marks are only valued at 1 and 0 hence there are two colours only. This is what I have done so far
x = c(3,0.5,1,0,0,0,2,2.5,5.5, 16,21,26,28,40, 47, 52, 58, 60, 65, 63, 63, 75, 77, 78, 75)
y = c(116,106,82.5,64,40,35,25,17.5,5,5,5,8,10,8, 14, 14, 10, 0, 0, 17, 20, 24, 30, 50, 116)
p <- owin(poly = cbind(x, y))
point_pattern = as.ppp(deviation_binary_locations_marks, p)
marks(point_pattern) <- deviation_binary_locations_marks[, "RPL32"]
colour <- c("green","black")[marks(point_pattern)]
plot(point_pattern,which.marks="RPL32", bg=colour, main="Point pattern for gene RPL32")
The circle size represents the mark values of either 1 or 0, and the colour represents the values correlated to the circle (green if the circle is 1, and black if the circle is 0). I also want it only shows two sizes of circles (value 1 and 0 since the marks are only 1 and 0). However, the attributes show multiple circle sizes from 0 to 1. How can I do that? Is there a way to make the plot looks better as well?