I have a simple data frame that I am trying to make into a plot. It is the concentration of a biomarker measured over time. There are some time points that do not have a value (NA).

I am trying to display the graph whereby the dots connect. When I do so using (na.omit), it messes up my x axis (-1, 24), it removes my NA values leaving me with only 18 points.

plot(time, pt, type="b", pch=16, col="blue", xlab="Time (months) relative to implant", ylab="Concentration (ng/ml)", main="OHdG Concentration Overtime", xaxt='n')

axis(1, at=seq(-1, 24))

Similar questions and discussions