Description Usage Arguments Details Value Author(s) See Also Examples
The PEST optimization routine of PestR is using factors to adjust the parameters of COSERO instead of adjusting the parameters itself. This has the advantage that all adjustable factors are in the same order of magnitude. factoval calculates the parameters from the factors that were adjusted by PEST. Factors in this sense must not be confused with factors in the R sense as in default.stringsAsFactors for instance. Needs a Transfermatrix and a matix containing the factors. Writes a matrix containing the parameters that can be read by COSERO.
1 | factoval(file_in,file_out,transferfile,NB,upriverNB=NB)
|
file_in |
A string pointing towards a file containing the factors (that will be optimized by PEST) |
file_out |
A string pointing towards the outputfile |
transferfile |
A string pointing towards a transfermatrix |
NB |
A numeric giving the number of the subbasin that will be optimized |
upriverNB |
A numeric or a numerical vator (see Details) |
The transfermatrix must be a matrix with as many columns as parameters that are optimized by PEST. The length (nrow) of the matrix must be the same as there are cells in the complete catchment (NZ). The values are the base which the factors are multiplied with. upriverNB gives the number of (ungauged) subbasins upriver from the subbasin which is optimized. The parameters of the upriverNB subbasins are adjusted, too.
Only writes a file containing the parameters for COSERO. Nothing is returned to R.
Simon Frey
readcosero
1 2 3 4 5 | factoval(file_in = paste(path.package("PestR"),"/extdata/sample/PEST_Para.txt",sep=""),
file_out = "PEST4COSERO.txt",
transferfile = paste(path.package("PestR"),"/extdata/sample/Baseparameters.txt",sep=""),
NB = 40,
upriverNB = c(38,39))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.