Description Usage Arguments Details Value References Examples
Read an Epanet .inp file into R
1 |
file |
the name of the file to read |
This function reads a text file in Epanet's .inp format and returns an S3 object with entries for sections of the .inp file. Sections of the .inp file that are implemented appear in the Value section.
Fields for node or link ID are stored as characters not factors or integers. However, some fields are stored as factors to allow more informative summaries. Examples include valve type and pipe status.
Sections that are absent from the .inp file are NULL in the list.
Columns of data.frames use the headings exported by the Epanet GUI.
The [OPTIONS] section in the .inp file is used to update a list of Epanet's default options. In this way if an option such as units is not specified by the .inp file, the units that would be used by default are provided.
In the [PATTERNS] and [CURVES] sections, integers used as names of list elements are backquoted according to the default behavior in R. So if the .inp file has a pattern "1" this pattern will appear as element '1' in the list that is returned. A warning is issued in this case.
Returns an epanet.inp S3 object with elements of the following names and types corresponding to sections of the .inp file. Sections missing from the .inp file have a value of NULL.
Title |
character |
Junctions |
data.frame |
Tanks |
data.frame |
Reservoirs |
data.frame |
Pipes |
data.frame |
Pumps |
data.frame |
Valves |
data.frame |
Demands |
data.frame |
Status |
data.frame |
Emitters |
data.frame |
Quality |
data.frame |
Sources |
data.frame |
Reactions |
character |
Mixing |
data.frame |
Patterns |
list |
Curves |
list |
Controls |
character |
Rules |
character |
Energy |
character |
Times |
character |
Report |
character |
Options |
list |
Coordinates |
data.frame |
Vertices |
data.frame |
Labels |
data.frame |
Backdrop |
character |
Tags |
character |
Rossman, L. A. (2000). Epanet 2 users manual. US EPA, Cincinnati, Ohio.
http://nepis.epa.gov/Adobe/PDF/P1007WWU.pdf
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.