Closed ldecicco-USGS closed 5 years ago
Your margin argument to timePlot can include a negative value to any axis side that you wish to suppress the ticks for. So in your code,
AA.gr = setGraph(2, AA.lo)
returns the following vector for the axes:
AA.gr
[1] NA NA 3.5 3.5
NA for bottom (I think this means “auto”), NA for left, 3.5 for the top, and 3.5 for the bottom. If you use a negative numbers instead of 3.5, it will suppress the ticks on that side. So
MillerCrkWQ.yr1.pl <- with(BOR_Q_yr1,timePlot(Date, MillerCrk_dailyQ_cfs,
Plot=list(name="Malone Daily Q-BOR", what="lines", color="blue"),
yaxis.log=FALSE, yaxis.range=c(-50,500),ytitle="Daily Streamflow(cfs)",
caption="Year 1", margin=c(NA,NA,3.5,-3.5), right=list(ticks=FALSE)))
works, or you can use the “noTicks” argument to “setGraph”:
AA.gr = setGraph(2, AA.lo, noTicks=c(4))
From an email:
I'm plotting some data on the right axis of a time series plot, but the first plot from the left axis has tick marks on the right axis, and there is overlap. I've been trying to use renderPretty, but not sure where it would go in the code below (not complete code, btw). Any ideas?