if (FALSE) {
# load and prepare data
data("winddata", package="bReeze")
set40 <- set(height=40, v.avg=winddata[,2], v.std=winddata[,5])
set30 <- set(height=30, v.avg=winddata[,6], v.std=winddata[,9])
set20 <- set(height=20, v.avg=winddata[,10], v.std=winddata[,13])
ts <- timestamp(timestamp=winddata[,1])
neubuerg <- mast(timestamp=ts, set40, set30, set20)
neubuerg <- clean(mast=neubuerg)
# plot
turb.iec.plot(mast=neubuerg, set=1)
turb.iec.plot(mast=neubuerg, set="set1") # same as above
# data subsets
turb.iec.plot(mast=neubuerg, set=1,
subset=c("2009-12-01 00:00:00", "2009-12-31 23:50:00"))
turb.iec.plot(mast=neubuerg, set=1,
subset=c("2010-01-01 00:00:00", NA)) # just 'start' time stamp
turb.iec.plot(mast=neubuerg, set=1,
subset=c(NA, "2009-12-31 23:50:00")) # just 'end' time stamp
# customize plot
turb.iec.plot(mast=neubuerg, set=1, bty="l", cex.axis=0.8, cex.lab=0.9,
cex.leg=0.7, col.axis="darkblue", col.box="lightblue", col.lab=
"darkblue", col.leg="darkblue", col.ticks="darkblue", las=0,
leg.text=c("IEC class A", "IEC class B", "IEC class C", "measured"),
mar=c(3,3,0.5,0.5), mgp=c(1.8,0.5,0), pos.leg="top", xlab="v [m/s]",
ylab="ti [-]", xlim=c(0,25), ylim=c(0,0.5), x.intersp=1, y.intersp=1)
# customize bars
turb.iec.plot(mast=neubuerg, set=1, col="gray", border="black", space=0.6)
# customize lines
turb.iec.plot(mast=neubuerg, set=1, line=gray(1:3 / 10), lty=2:4,
lwd=0.5:2.5)
}
Run the code above in your browser using DataLab