# load and prepare data
data(winddata)
set1 <- createSet(height=40, v.avg=winddata[,2], v.std=winddata[,5],
dir.avg=winddata[,14])
set2 <- createSet(height=30, v.avg=winddata[,6], v.std=winddata[,9],
dir.avg=winddata[,16])
set3 <- createSet(height=20, v.avg=winddata[,10], v.std=winddata[,13])
ts <- formatTS(time.stamp=winddata[,1])
neubuerg <- createMast(time.stamp=ts, set1, set2, set3)
neubuerg <- clean(mast=neubuerg)
# calculate Weibull object
neubuerg.wb <- weibull(mast=neubuerg, v.set=1, print=FALSE)
# calculate energy
energy(wb=neubuerg.wb)
# calculate energy for 1 m/s speed bins and without binning
energy(wb=neubuerg.wb, bins=0:25)
energy(wb=neubuerg.wb, bins=NULL)
# calculate energy with site specific air density
energy(wb=neubuerg.wb, rho=1.115, bins=NULL)
# change number of digits and hide results
energy(wb=neubuerg.wb, digits=2)
energy(wb=neubuerg.wb, print=FALSE)
Run the code above in your browser using DataLab