Skip to content
rcapell edited this page Sep 5, 2022 · 58 revisions

CRAN status Conda Version R-CMD-check License: LGPL v3

HYPEtools package

Summary

HYPEtools is an add-on package to the R software environment, providing functions to work with the hydrological model HYPE. HYPE and HYPEtools are projects developed by the Swedish Meteorological and Hydrological Institute (SMHI).

Installation

HYPEtools release versions starting with v1.0.0 are available from CRAN. If you want to install the latest development snapshot, please look here for instructions.

Package contents

HYPEtools contains some 80-odd functions at the moment. To browse its contents, please download the HYPEtools reference card which provides a grouped overview over all functions in the package.

HYPEtools master contains the following functions and S3 methods:

AllDownstreamSubids Find All Downstream SUBIDs
AllUpstreamSubids Find All Upstream SUBIDs
AnnualRegime Calculate annual regimes
BarplotUpstreamClasses Bar plots of upstream-averaged classes of HYPE sub-basins
BoxplotSLCClasses Box plots of SLC distributions
CleanSLCClasses Clean Soil-Landuse classes (SLCs) from small fractions
CompareFiles Compare HYPE model files to identify any differences.
ConvertDischarge Calculate Specific runoff from volumetric discharge and vice versa
CreateOptpar Create an optpar list
CustomColors Custom color ramp palettes
datetime Quickly query and set HYPE-specific attributes
DirectUpstreamSubids Find Direct Upstream SUBIDs, with Flow Fractions
EquallySpacedObs Create an equally spaced time series from irregular observations
ExtractFreq Extract quantiles for use in a frequency distribution plot, e.g. a flow duration curve
ExtractStats Extract statistics from time series
GroupSLCClasses Calculate grouped sums for SLC classes in a GeoData file
GwRetention Calculate groundwater retention of nutrients
HeadwaterSubids Find all headwater SUBIDs of a model domain
HypeAttrAccess Quickly query and set HYPE-specific attributes
HypeDataExport Write HYPE data files
HypeDataImport Read HYPE data files
HypeGeoData HypeGeoData data frames
HypeMultiVar HypeMultiVar arrays
HypeSingleVar HypeSingleVar arrays
HypeSubidChecks Check HYPE SUBID properties
HYPEtools HYPEtools: Tools to work with HYPE model set-ups and results
hypeunit Quickly query and set HYPE-specific attributes
HypeXobs HypeXobs data frames
IsHeadwater Check HYPE SUBID properties
IsOutlet Check HYPE SUBID properties
IsRegulated Check HYPE SUBID properties
MapRegionalSources Map regional irrigation source connection as spatial lines
merge.HypeGeoData Merge HypeGeoData object
MergeXobs Merge two Xobs data frames
NSE.HypeSingleVar Nash-Sutcliffe Efficiency
obsid Quickly query and set HYPE-specific attributes
OptimisedClasses Get optimised classes from an imported optpar.txt file
OutletIds Find Outlet IDs
OutletNearObs Find outlet-near observations in HYPE observation data files.
OutletSubids Find all Outlet SUBIDs of a model domain
outregid Quickly query and set HYPE-specific attributes
pbias.HypeSingleVar Percent bias
PlotAnnualRegime Plot annual regimes
PlotBasinOutput Plot a suite of time series plots from a HYPE basin output file
PlotBasinSummary Plot a summary of model results for a single sub-basin
PlotDurationCurve Plot duration curves
PlotMapOutput Plot function for HYPE map results.
PlotMapPoints Plot function for mapped point information
PlotSimObsRegime Plot annual regimes of simulated and observed variables
PlotSubbasinRouting Plot HYPE model subbasin routing.
r.HypeSingleVar Pearson product-moment correlation coefficient r
ReadAllsim Read HYPE data files
ReadAquiferData Read HYPE data files
ReadBasinOutput Read a Basin Output File
ReadBranchData Read HYPE data files
ReadCropData Read HYPE data files
ReadDamData Read HYPE data files
ReadDescription Read a 'description.txt' file
ReadForcKey Read HYPE data files
ReadGeoClass Read a 'GeoClass.txt' File
ReadGeoData Read a 'GeoData.txt' file
ReadGlacierData Read HYPE data files
ReadInfo Read an 'info.txt' file
ReadLakeData Read HYPE data files
ReadMapOutput Read a Map Output File
ReadMgmtData Read HYPE data files
ReadObs Read HYPE observation data files
ReadOptpar Read an 'optpar.txt' file
ReadOutregions Read HYPE data files
ReadPar Read a 'par.txt' file
ReadPmsf Read a 'pmsf.txt' file
ReadPointSourceData Read HYPE data files
ReadPTQobs Read HYPE observation data files
ReadSimass Read a 'simass.txt' file
ReadSubass Read a 'subassX.txt' file
ReadTimeOutput Read a Time Output File
ReadUpdate Read HYPE data files
ReadWsOutput Read optimisation simulation results
ReadXobs Read an 'Xobs.txt' file
RescaleSLCClasses Re-scale SLC classes in a GeoData data frame
SortGeoData Sort a GeoData dataframe in downstream order
subid Quickly query and set HYPE-specific attributes
SumSLCClasses Calculate sums of SLC classes in a GeoData file
SumUpstreamArea Calculate upstream area sums
timestep Quickly query and set HYPE-specific attributes
UpstreamGeoData Calculate upstream sums and averages of selected GeoData contents
UpstreamGroupSLCClasses Calculate area-weighted upstream averages of grouped SLC class fractions.
UpstreamPointSources Summarize point source emissions of all upstream areas
UpstreamSLCClasses Calculate SLC class fractions of all upstream areas
variable Quickly query and set HYPE-specific attributes
VariableInfo Lookup Functions For HYPE Variables
VariableLookup Lookup Functions For HYPE Variables
VariableSearch Lookup Functions For HYPE Variables
WriteAquiferData Write HYPE data files
WriteBasinOutput Write a basin output '[SUBID].txt' file
WriteBranchData Write HYPE data files
WriteCropData Write HYPE data files
WriteDamData Write HYPE data files
WriteForcKey Write HYPE data files
WriteGeoClass Write a 'GeoClass.txt' file
WriteGeoData Write a 'GeoData.txt' file
WriteLakeData Write HYPE data files
WriteMapOutput Write a 'mapXXXX.txt' file
WriteMgmtData Write HYPE data files
WriteOptpar Write an 'optpar.txt' File
WriteOutregions Write HYPE data files
WritePar Write a 'par.txt' File
WritePmsf Write a 'pmsf.txt' file
WritePointSourceData Write HYPE data files
WriteObs Write 'Pobs.txt', 'Tobs.txt', 'Qobs.txt', and other observation data files
WriteTimeOutput Write a 'timeXXXX.txt' file
WriteXobs Write an 'Xobs.txt' File

Function dependencies (not fully updated with all functions atm)

Package-internal function dependencies.