calcaPMV | R Documentation |
Function to calculate adaptive Predicted Mean Vote (aPMV) adjusted through the adaptive coefficient.
calcaPMV(ta, tr, vel, rh, clo = 0.5, met = 1, wme = 0, apCoeff)
ta |
a numeric value presenting air temperature in [degree C] |
tr |
a numeric value presenting mean radiant temperature in [degree C] |
vel |
a numeric value presenting air velocity in [m/s] |
rh |
a numeric value presenting relative humidity [%] |
clo |
a numeric value presenting clothing insulation level in [clo] |
met |
a numeric value presenting metabolic rate in [met] |
wme |
a numeric value presenting external work in [met] |
apCoeff |
adaptive coefficient lambda |
apCoeff
can be derived using calcapCoeff
.
calcaPMV
returns the predicted mean vote adjusted through the adaptive coefficients.
In case one of apCoeff
is not given, a standard value will be taken from a list (see createCond
for details.
Code implemented in to R by Marcel Schweiker. Further contribution by Sophia Mueller and Shoaib Sarwar.
aPMV is based on Yao, Li and Liu (2009) <doi:10.1016/j.buildenv.2009.02.014>
calcComfInd
, calcapCoeff
## Note. Due to random generated asv values. The values for the coefficients will not be meaningful.
## Create sample data
ta <- 20:24 # vector with air temperature values
tr <- ta # vector with radiant temperature values
vel <- rep(.1,5) # vector with air velocities
rh <- rep(50,5) # vector with relative humidity values
clo <- rep(1.0,5) # vector with clo values
met <- rep(1.1,5) # vector with metabolic rates
asv <- rnorm(5) # vector with actual sensation votes
lsCond <- as.list(data.frame(ta,tr,vel,rh,clo,met,asv))
## Calculate coefficient apCoeff for data set
apCoeff <- calcapCoeff(lsCond)
## calculate apmv
apmv <- NULL
for (i in 1:length(ta)){
apmv[i] <- calcaPMV(ta[i], tr[i], vel[i], rh[i], clo[i], met[i], apCoeff = apCoeff)$apmv}
apmv
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.