ggof {hydroGOF} | R Documentation |

Graphical comparison between two vectors (numeric, ts or zoo), with several numerical goodness of fit printed as a legend.

Missing values in observed and/or simulated values can removed before the computations.

ggof(sim, obs, na.rm = TRUE, dates, date.fmt = "%Y-%m-%d", pt.style = "ts", ftype = "o", FUN, stype="default", season.names=c("Winter", "Spring", "Summer", "Autumn"), gof.leg = TRUE, digits=2, gofs=c("ME", "MAE", "RMSE", "NRMSE", "PBIAS", "RSR", "rSD", "NSE", "mNSE", "rNSE", "d", "md", "rd", "r", "R2", "bR2", "KGE", "VE"), legend, leg.cex=1, tick.tstep = "auto", lab.tstep = "auto", lab.fmt=NULL, cal.ini=NA, val.ini=NA, main, xlab = "Time", ylab=c("Q, [m3/s]"), col = c("blue", "black"), cex = c(0.5, 0.5), cex.axis=1.2, cex.lab=1.2, lwd = c(1, 1), lty = c(1, 3), pch = c(1, 9), ...)

`sim` |
numeric or zoo object with with simulated values |

`obs` |
numeric or zoo object with observed values |

`na.rm` |
a logical value indicating whether 'NA' should be stripped before the computation proceeds. |

`dates` |
character, factor, Date or POSIXct object indicating how to obtain the dates for the corresponding values in the |

`date.fmt` |
OPTIONAL. character indicating the format in which the dates are stored in |

`pt.style` |
Character indicating if the 2 ts have to be plotted as lines or bars. When |

`ftype` |
Character indicating how many plots are desired by the user. Valid values are: |

`FUN` |
OPTIONAL, ONLY required when |

`stype` |
OPTIONAL, only used when |

`season.names` |
OPTIONAL, only used when |

`gof.leg` |
logical, indicating if several numerical goodness of fit have to be computed between |

`digits` |
OPTIONAL, only used when |

`gofs` |
character, with one or more strings indicating the goodness-of-fit measures to be shown in the legend of the plot when |

`legend` |
character of length 2 to appear in the legend. |

`leg.cex` |
OPTIONAL. ONLY used when |

`tick.tstep` |
character, indicating the time step that have to be used for putting the ticks on the time axis. Valid values are: |

`lab.tstep` |
character, indicating the time step that have to be used for putting the labels on the time axis. Valid values are: |

`lab.fmt` |
Character indicating the format to be used for the label of the axis. See |

`cal.ini` |
OPTIONAL. Character, indicating the date in which the calibration period started. |

`val.ini` |
OPTIONAL. Character, the date in which the validation period started. |

`main` |
character representing the main title of the plot. |

`xlab` |
label for the 'x' axis. |

`ylab` |
label for the 'y' axis. |

`col` |
character, representing the colors of |

`cex` |
numeric, representing the values controlling the size of text and symbols of 'x' and 'y' with respect to the default |

`cex.axis` |
numeric, representing the magnification to be used for the axis annotation relative to 'cex'. See |

`cex.lab` |
numeric, representing the magnification to be used for x and y labels relative to the current setting of 'cex'. See |

`lwd` |
vector with the line width of |

`lty` |
numeric with the line type of |

`pch` |
numeric with the type of symbol for |

`...` |
further arguments passed to or from other methods. |

Plots observed and simulated values in the same graph.

If `gof.leg=TRUE`

, it computes the numerical values of:

'me', 'mae', 'rmse', 'nrmse', 'PBIAS', 'RSR, 'rSD', 'NSE', 'mNSE', 'rNSE', 'd', 'md, 'rd', 'cp', 'r', 'r.Spearman', 'R2', 'bR2', 'KGE', 'VE'

`me` |
Mean Error |

`mae` |
Mean Absolute Error |

`rmse` |
Root Mean Square Error |

`nrmse` |
Normalized Root Mean Square Error |

`PBIAS` |
Percent Bias |

`pbiasfdc` |
PBIAS in the slope of the midsegment of the Flow Duration Curve |

`RSR` |
Ratio of RMSE to the Standard Deviation of the Observations, RSR = rms / sd(obs). ( 0 <= RSR <= +Inf ) |

`rSD` |
Ratio of Standard Deviations, rSD = sd(sim) / sd(obs) |

`NSE` |
Nash-Sutcliffe Efficiency ( -Inf <= NSE <= 1 ) |

`mNSE` |
Modified Nash-Sutcliffe Efficiency |

`rNSE` |
Relative Nash-Sutcliffe Efficiency |

`d` |
Index of Agreement ( 0 <= d <= 1 ) |

`md` |
Modified Index of Agreement |

`rd` |
Relative Index of Agreement |

`cp` |
Persistence Index ( 0 <= PI <= 1 ) |

`r` |
Pearson product-moment correlation coefficient ( -1 <= r <= 1 ) |

`r.Spearman` |
Spearman Correlation coefficient ( -1 <= r.Spearman <= 1 ) |

`R2` |
Coefficient of Determination ( 0 <= R2 <= 1 ). |

`bR2` |
R2 multiplied by the coefficient of the regression line between |

`KGE` |
Kling-Gupta efficiency between |

`VE` |
Volumetric efficiency between |

Mauricio Zambrano Bigiarini <mzb.devel@gmail.com>

Legates, D. R., and G. J. McCabe Jr. (1999), Evaluating the Use of "Goodness-of-Fit" Measures in Hydrologic and Hydroclimatic Model Validation, Water Resour. Res., 35(1), 233–241

Krause P., Boyle D.P., and B\"ase F., Comparison of different efficiency criteria for hydrological model assessment, Advances in Geosciences 5 (2005), pp. 89–97

Moriasi, D.N., Arnold, J.G., Van Liew, M.W., Bingner, R.L., Harmel, R.D., Veith, T.L. 2007. Model evaluation guidelines for systematic quantification of accuracy in watershed simulations

Transactions of the ASABE. 50(3):885-900

Boyle, D. P., H. V. Gupta, and S. Sorooshian (2000), Toward Improved Calibration of Hydrologic Models: Combining the Strengths of Manual and Automatic Methods, Water Resour. Res., 36(12), 3663–3674

Kitanidis, P. K., and R. L. Bras (1980), Real-Time Forecasting With a Conceptual Hydrologic Model 2. Applications and Results, Water Resour. Res., 16(6), 1034–1044

J.E. Nash and J.V. Sutcliffe, River flow forecasting through conceptual models. Part 1: a discussion of principles, J. Hydrol. 10 (1970), pp. 282–290

Yapo P. O., Gupta H. V., Sorooshian S., 1996. Automatic calibration of conceptual rainfall-runoff models: sensitivity to calibration data. Journal of Hydrology. v181 i1-4. 23–48

Yilmaz, K. K., H. V. Gupta, and T. Wagener (2008), A process-based diagnostic approach to model evaluation: Application to the NWS distributed hydrologic model, Water Resour. Res., 44, W09417, doi:10.1029/2007WR006716

Hoshin V. Gupta, Harald Kling, Koray K. Yilmaz, Guillermo F. Martinez. Decomposition of the mean squared error and NSE performance criteria: Implications for improving hydrological modelling. Journal of Hydrology, Volume 377, Issues 1-2, 20 October 2009, Pages 80-91. DOI: 10.1016/j.jhydrol.2009.08.003. ISSN 0022-1694

Criss, R. E. and Winston, W. E. (2008), Do Nash values have value? Discussion and alternate proposals. Hydrological Processes, 22: 2723-2725. doi: 10.1002/hyp.7072

`gof`

, `plot2`

,
`me`

, `mae`

, `rmse`

, `nrmse`

, `pbias`

,
`pbiasfdc`

, `rSD`

, `NSE`

, `mNSE`

, `rNSE`

,
`d`

, `md`

, `rd`

, `cp`

, `br2`

, `KGE`

, `VE`

obs <- 1:10 sim <- 2:11 ## Not run: ggof(sim, obs) ## End(Not run) ################## # Loading daily streamflows of the Ega River (Spain), from 1961 to 1970 data(EgaEnEstellaQts) obs <- EgaEnEstellaQts # Generating a simulated daily time series, initially equal to the observed series sim <- obs # Getting the numeric goodness of fit for the "best" (unattainable) case gof(sim=sim, obs=obs) # Randomly changing the first 2000 elements of 'sim', by using a normal distribution # with mean 10 and standard deviation equal to 1 (default of 'rnorm'). sim[1:2000] <- obs[1:2000] + rnorm(2000, mean=10) # Getting the new numeric goodness-of-fit measures gof(sim=sim, obs=obs) # Getting the graphical representation of 'obs' and 'sim' along with the numeric # goodness-of-fit measures for the daily and monthly time series ## Not run: ggof(sim=sim, obs=obs, ftype="dm", FUN=mean) ## End(Not run) # Getting the graphical representation of 'obs' and 'sim' along with some numeric # goodness-of-fit measures for the seasonal time series ## Not run: ggof(sim=sim, obs=obs, ftype="seasonal", FUN=mean) ## End(Not run) # Computing the daily residuals # even if this is a dummy example, it is enough for illustrating the capability r <- sim-obs # Summarizing and plotting the residuals ## Not run: library(hydroTSM) # summary smry(r) # daily, monthly and annual plots, boxplots and histograms hydroplot(r, FUN=mean) # seasonal plots and boxplots hydroplot(r, FUN=mean, pfreq="seasonal") ## End(Not run)

[Package *hydroGOF* version 0.3-10 Index]