# load and prepare data
data(winddata)
set1 <- createSet(height=40, v.avg=winddata[,2], dir.avg=winddata[,14])
ts <- formatTS(time.stamp=winddata[,1])
neubuerg <- createMast(time.stamp=ts, set1)
neubuerg <- clean(mast=neubuerg)
# calculate Weibull parameters
neubuerg.wb <- weibull(mast=neubuerg, v.set=1, print=FALSE)
# plot
plotWbDir(wb=neubuerg.wb)
# show parameters in legend
plotWbDir(wb=neubuerg.wb, show.ak=TRUE)
# customize plot
plotWbDir(wb=neubuerg.wb, bty="l", bty.leg="o", cex.axis=0.8, cex.lab=0.9,
cex.leg=0.7, col=c(rainbow(12), gray(0.4)), col.axis=gray(0.2),
col.box=gray(0.4), col.lab=gray(0.2), col.leg=gray(0.2),
col.ticks=gray(0.2), las=0, lty=c(rep(3, 12), 1), lwd=c(rep(1, 12), 2),
mar=c(3,3,0.5,0.5), mgp=c(1.5,0.5,0), pos.leg="right",
xlab="velocity [m/s]", ylab="frequency [m/s]", xlim=c(0,15),
ylim=c(0,25), x.intersp=1, y.intersp=1)
Run the code above in your browser using DataLab