Learn R Programming

bReeze (version 0.2-2)

availability: Calculate availability for pairs of wind speed and direction

Description

Calculates the availability for pairs of wind speed and wind direction of a met mast.

Usage

availability(mast, v.set, dir.set, digits=1, print=TRUE)
avail(mast, v.set, dir.set, digits=1, print=TRUE)

Arguments

mast
Met mast object created by createMast.
v.set
Set(s) to be used for wind speed, specified as set number(s) or set name(s). Argument is optional -- if missing, all sets containing wind speed and wind direction data are used.
dir.set
Set(s) to be used for wind direction, specified as set number(s) or set name(s). Argument is optional -- if missing, the set(s) used for wind speed data will also be used for wind direction.
digits
Number of decimal places to be used for results as numeric value. Default is 1.
print
If TRUE, results are printed directly.

Value

  • Returns a list of sub lists for each pair of v.set/dir.set containing:
  • totalTotal availability (%), effective period (days) and total period (days) of a set/pair of wind speed and direction.
  • dailyAvailability per day, i.e. number of samples per day.

encoding

UTF-8

Details

The availability is the number of pairs of valid wind speed and valid wind direction data samples as a percentage of the total possible for the measurement period, i.e.: $$Availability = \frac{N(v_{valid} \wedge dir_{valid})}{N}$$ where $N$ is the total possible number of samples and $v_{valid} \wedge dir_{valid}$ is a pair of valid wind speed and direction data.

Causes of invalid or missing data are manifold. Typical causes are icing and defects of sensors or other measurement equipment.

References

Brower, M., Marcus, M., Taylor, M., Bernadett, D., Filippelli, M., Beaucage, P., Hale, E., Elsholz, K., Doane, J., Eberhard, M., Tensen, J., Ryan, D. (2010) Wind Resource Assessment Handbook. http://www.awstruepower.com/wp-content/uploads/2012/01/10-30_wind-resource-handbook.pdf

See Also

createMast, clean, plotAvailability, printObject

Examples

Run this code
# load and prepare data
data(winddata)
set40 <- createSet(height=40, v.avg=winddata[,2], v.std=winddata[,5],
  dir.avg=winddata[,14])
set30 <- createSet(height=30, v.avg=winddata[,6], v.std=winddata[,9],
  dir.avg=winddata[,16])
set20 <- createSet(height=20, v.avg=winddata[,10], v.std=winddata[,13])
ts <- formatTS(time.stamp=winddata[,1])
neubuerg <- createMast(time.stamp=ts, set40=set40, set30=set30, 
  set20=set20)
neubuerg <- clean(mast=neubuerg)

# calculate availability
neubuerg.avail <- availability(mast=neubuerg)

# compare the total availability of 'set40' and 'set30'
neubuerg.avail$set40$total
neubuerg.avail$set30$total

# check the daily availability of 'set40'
neubuerg.avail$set40$daily

# note: availability for 'set20' is missing - its availability is NULL,
# since it does not contain wind direction data

# calculate availability for 'set20' using wind direction data from 'set40'
set20.avail <- availability(mast=neubuerg, v.set=3, dir.set=1)
# same as above
set20.avail <- availability(mast=neubuerg, v.set="set20", dir.set="set40")

# calculate availability for all sets using wind direction data from 'set40'
neubuerg.avail <- availability(mast=neubuerg, v.set=c(1,2,3), dir.set=1)

Run the code above in your browser using DataLab