Processing math: 100%
Skip to contents

Compute the MQI for yearly average model results.

Usage

mqi_year(
  times,
  obs,
  pred,
  beta = 2,
  alpha = 0.2,
  RV = 200,
  U_RV = 0.24,
  Np = 5.2,
  Nnp = 5.5,
  ...
)

Arguments

times

A numeric vector, data.frame or data.table representing the deadlines of obs and pred vectors.

obs

A numeric vector, data.frame or data.table of observed data. It must be of the same length of times.

pred

A numeric vector, data.frame or data.table of predicted (model) data. It must be of the same length of times.

beta

An integer: in Fairmode it is arbitrarily set to 2. It determines the stringency of the Modelling Quality Objectice (MQO).

alpha

Non-proportional fraction factor (0 <= a <= 1). Default value = 0.2 (for NO_2).

RV

Reference value. Default value = 200 (for NO_2).

U_RV

Standard measurement uncertainty around the RV. Default value = 0.24 (for NO_2).

Np

Parameter to account for the compensation of errors. Default value = 5.2 (for NO_2).

Nnp

Parameter to account for the compensation of errors. Default value = 5.5 (for NO_2).

...

Optional arguments passed to timeAggregation.

Value

A data.frame with mqi value for each year.

Details

The function computes the Modelling Quality Indicator (MQI) for yearly averaged pollutant concentrations according to the definition: MQI=|ˉOˉP|βU(ˉO) See Section 5.2.2 of Fairmode MQO Guidance V3.2 for further details and Annex I therein for parameter values for other pollutants.

Examples


library(lubridate)
#> 
#> Attaching package: ‘lubridate’
#> The following objects are masked from ‘package:base’:
#> 
#>     date, intersect, setdiff, union
times <- seq(dmy_hm("1/1/2019 00:00"), dmy_hm("31/12/2019 23:00"), by = "1 hour")
x <- runif(1:8760) * 10
y <- runif(1:8760) * 10
mqi_year(times = times, obs = x, pred = y)
#>     year         mqi
#>    <num>       <num>
#> 1:  2019 0.003940269