Link to USGS home
Surface Water Information--Data Scripts

sendrat

This script is not yet supported (and may never be), but is provided in the interim because many users may find it valuable. Questions about this script should be referred to the script author. The status of the script is noted.

Name:
sendrat - email cooperators/interested parties notifications of shift/rating changes and provide access to a current shifted rating table.

Information:

This utility sends cooperators or other interested parties a notification that a rating or shift has changed at a station of interest and provides them with access to a current shifted rating table both directly in the email and via a link to a pdf rating table.

Program summary:

  1. Sends email to either built-in WSC lists of email addresses or user-specified email addresses alerting recipients to a shift or rating change at the station.
  2. Triggers a retrieval of changed shifts/ratings to the rating depot if user is a member of nwweb group.
  3. Email includes a text shifted rating table as part of the email (which may not display well depending on the email system used by the recipient).
  4. Also outputs a pdf shifted rating table to a server-specific output directory that should be set up for web display – script set up is geared towards a /var/ftp/pub area that routinely syncs files to the enterprise ftp server (ftpext.cr.usgs.gov). Email will include a link to that file.

USAGE: sendrat

No command-line options are currently supported – user will be prompted for required information.

Example email:

Please note that this rating table is provisional and subject to revision.


  A PDF version of the rating table can be obtained from this URL (rating is also included below, directly in this email, but may not display well depending on the email program being used):

   ftp://ftpext.cr.usgs.gov/pub/cr/co/lakewood/wsc/coop_ratings/07106500.rating.2011-03-14.pdf

  Note: File will be deleted after about 90 days.


  Real-time data for station are available here - a link to a spreadsheet compatible version of the shifted rating table is also available from this page:

   http://waterdata.usgs.gov/nwis/uv/?site_no=07106500&PARAmeter_cd=00065,00060

  Thank you for your use and support of USGS water data.

 ___________________________________________________________________________________________________________________________________


                            U.S. DEPARTMENT OF THE INTERIOR - U.S. GEOLOGICAL SURVEY - WATER RESOURCES

                 STATION:07106500  FOUNTAIN CREEK AT PUEBLO, CO.  TYPE:STREAM  AGENCY:USGS   STATE:08  COUNTY:101

         LATITUDE: 381716  LONGITUDE: 1043602 NAD27  DRAINAGE AREA:926   CONTRIBUTING DRAINAGE AREA:   DATUM:4705 NGVD29
                                            Date Processed: 2011-03-14 13:02 By walker
                                                    Rating for Discharge (cfs)
                                                  Shifted for 20110314125356 MDT
                       RATING ID: 31   TYPE: stage-discharge    EXPANSION: logarithmic    STATUS: approved
               Created by bdbemis on 06-17-2010 @ 15:11:09 MDT,    Updated by bdbemis on 10-08-2010 @ 15:06:11 MDT

  RATING REMARKS:    Same as Rating 30 from 5.84 feet, rating based on channel scour.

OFFSET: 3.00


                                                      EXPANDED RATING TABLE

  Gage                                                                                                                    DIFF IN Q
height,                        Discharge (cfs)                     (EXPANDED PRECISION)                                      PER
  feet        .00        .01        .02        .03        .04        .05        .06        .07        .08        .09      .1 UNITS

   3.00                              0.150      0.199      0.256      0.324      0.403      0.494      0.597      0.713      0.866
   3.10        0.843*     0.989       1.15       1.33       1.52       1.73       1.96       2.21       2.48       2.78       2.25
   3.20         3.09       3.42       3.78       4.16       4.57       5.00       5.46       5.95       6.46       7.00       4.48
   3.30         7.57       8.17       8.80       9.47      10.16      10.89      11.65      12.44      13.27      14.14       7.47
   3.40        15.04      15.98      16.96      17.97      19.03      20.12      21.26      22.44      23.66      24.92      11.18

   3.50        26.22      27.57      28.97      30.41      31.90      33.43      35.02      36.65      38.33      40.06      15.62
   3.60        41.84      43.68      45.56      47.50      49.49      51.54      53.64      55.80      58.01      60.28      20.77
   3.70        62.61      65.00      67.44      69.95      72.52      75.15      77.84      80.59      83.41      86.29      26.63
   3.80        89.24      92.25      95.32      98.47      101.7      105.0      108.3      111.7      115.2      118.8      33.16
   3.90        122.4      126.1      129.9      133.8      137.7      141.7      145.8      149.9      154.2      158.5      40.50

   4.00        162.9      167.3      171.9      176.5      181.2      186.0      190.9      195.8      200.9      206.0      48.30
   4.10        211.2      216.5      221.9      227.4      233.0      238.6      244.4      250.2      256.1      262.1      57.10
   4.20        268.3      274.5      280.3      286.3      292.3      298.4      304.6      310.9      317.2      323.7*     61.90
   4.30        330.2      336.8      343.5      350.2      357.1      364.0      371.0      378.1      385.3      392.6      69.80
   4.40        400.0      407.4      415.0      422.6      430.3      438.1      446.0      454.0      462.0      470.2      78.50

   4.50        478.5      486.8      495.2      503.8      512.4      521.1      529.9      538.8      547.8      556.9      87.60
   4.60        566.1      575.4      584.8      594.2      603.8      613.5      623.3      633.1      643.1      653.2      97.20
   4.70        663.3      663.3      673.6      684.0      694.4      705.0      715.6      726.4      737.3      748.3      96.00
   4.80        759.3      770.5      781.8      793.2      804.7      816.3      828.0      839.8      851.7      863.8      116.6
   4.90        875.9      888.1      888.1      900.5      912.9      925.5      938.2      951.0      963.9      976.9      114.1

   5.00        990.0       1003       1017       1030       1044       1057       1071       1085       1099       1113      137.0
   5.10         1127       1142       1156       1156       1171       1185       1200       1215       1230       1245      134.0
   5.20         1261       1276       1292       1307       1323       1339       1355       1371       1387       1404      159.0
   5.30         1420       1437       1454       1471       1471       1488       1505       1522       1539       1557      154.0
   5.40         1574       1592       1610       1628       1646       1664       1683       1701       1720       1739      184.0

   5.50         1758       1777       1796       1815       1835       1854       1854       1874       1894       1914      176.0
   5.60         1934       1954       1974       1995       2015       2036       2057       2078       2099       2121      208.0
   5.70         2142       2164       2185       2207       2229       2251       2273       2273       2296       2318      199.0
   5.80         2341       2364       2387       2410       2434       2458*      2483       2507       2532       2557      241.0
   5.90         2582       2607       2632       2657       2683       2709       2735       2761       2761       2787      231.0

   6.00         2813       2840       2867       2894       2921       2948       2975       3003       3031       3058      274.0
   6.10         3087       3115       3143       3172       3200       3229       3258       3287       3317       3317      259.0
   6.20         3346       3376       3406       3436       3466       3497       3527       3558       3589       3620*     299.0
   6.30         3645       3669       3694       3719       3744       3769       3794       3819       3845       3870      251.0
   6.40         3896       3921       3947       3973       3999       4025       4051       4077       4103       4130      260.0

   6.50         4156       4183       4209       4236       4263       4290       4317       4344       4371       4398      270.0
   6.60         4426       4453       4481       4509       4536       4564       4592       4620       4648       4677      279.0
   6.70         4705       4733       4762       4790       4819       4848       4877       4906       4935       4964      288.0


_                            U.S. DEPARTMENT OF THE INTERIOR - U.S. GEOLOGICAL SURVEY - WATER RESOURCES
            

Script Language:
ksh

Requirements:

Author(s): (for unsupported scripts, please address questions/comments to the author)
Original author Wade Walker (walker@usgs.gov)

Known Problems/Limitations/Need Improvements:

Installation:

  1. Download and unzip the file to your NWIS server.
  2. Open the file in a UNIX text editor (don’t use a Windows editor unless it supports UNIX output!) and edit the “outdir=”, “webdir=”, “list#text=”, and “emailadd#=” settings near the top of the script as explained directly within the script.
  3. Make executable (chmod +x sendrat).
  4. Run by typing ‘sendrat’. You will be prompted for everything.

Latest Version Release Notes:

Version 1.0 (Posted 03/23/11):
- Initial (unsupported) release.
pb download (Zip file = 5.3K)

Back to Scripts
[an error occurred while processing this directive]