I'm generating a polar chart in R with plotrix. The angle is record hearding and the length is taken from the record timestamp. The dates are parsed with lubridate parse_date_time
polar.plot(
as.numeric(df$datetime),
df$heading,
rp.type="p",
start=90,
clockwise=TRUE,
show.grid.labels=FALSE
)
The issue I have is that polygon links the first and last points. I also have a few gaps in the data. These two circumstances lead to lines of the polygon crossing over the middle of the chart. Ideally, I wouldn't link the first and last points and I'd break the connecting lines whenever there's a significant gap in the time-series.
I'm already calculating the delta between each record, so it is easy enough to identify where I want those gaps to occur.
I'm not tied to plotrix if there is another way to achieve these goals.
Thanks for any help.