PCRANCH

Download weather data from CIMIS website

The California Irrigation Management Information System (CIMIS) is a program in the Office of Water Use Efficiency (OWUE), California Department of Water Resources (DWR) that manages a network of over 120 automated weather stations in the state of California. CIMIS was developed in 1982 by the California Department of Water Resource and the University of California at Davis to assist California’s irrigators manage their water resources efficiently.

To download the weather data from CIMIS web site you must first registder by visiting the following site: 
http://wwwcimis.water.ca.gov/Auth/Register.aspx

Once you have registered, follow these steps:

  1. Login to the following site using your registered user name and password:
  2. http://wwwcimis.water.ca.gov/Auth/Login.aspx
  3. Click the Data tab. The CIMIS Station Reports dialog box appears.
  4. Create a Daily CVS report in Metric Units from 1/1/210 to 1/1/2016
  5. Select a station from the list. For example station number 002, FivePoints, San Joaquin Valley, Fresno.
  6. Check the check box for "Select sensors" and then select the following seven sensors:
    • Percipitation
    • Solar Radiation  Average
    • Maxium Air Temperature
    • Minimum Air Temperature
    • Average Air Temperature
    • Average Wind Speed
    • Percipitation
    • Average Relative Humidity
  7. click the Run Report button. The system creates a CSV file named daily.csv and gives you the option of opening it with Excel program or saving it on your desktop.
  8. Open the daily.csv file with Excel program and save it with different name. The file name must start with the word CIMIS and then an underscore and then a number such as 2 (staion number). The extension for the file must be CSV (Comma Separated Values). For example: CIMIS_2.CSV.This naming method is very important, because our Convert program looks for files like CIMIS_*.CSV .
  9. Save your file in a folder called C:\CIMIS\

Repeat steps1 through 9 for other weather stations or other years. Sometimes, you can select multiple weather stations from the Station List by holding down the Control Key and clicking on more than one entry. Try to not select more than three stations, otherwise, the web site refuses to process your request and displays an error

The generated CSV file has 19 columns.

  1. Stn Id
  2. Stn Name
  3. CIMIS Region
  4. Date
  5. Jul
  6. Precip (mm)
  7. qc
  8. Sol Rad (W/sq.m)
  9. qc
  10. Max Air Temp (C)
  11. qc
  12. Min Air Temp (C)
  13. qc
  14. Avg Air Temp (C)
  15. qc
  16. Avg Rel Hum (%)
  17. qc
  18. Avg Wind Speed (m/s)
  19. qc

The "qc" stands for Quality Control and contains special codes related to the value of the pevious column. For example the code M means missing. For a complete list of codes visit the CIMIS web site. As you see, the computer adds several columns besides the seven columns you specified in the Sensor List, such as Stn Id, Station, Region, Date, Jul (Julian Date) and seven extra qc columns for quality control.

Conversion to PCRANCH format

After you have downloaded all weather data, copy the downloaded file onto the ‘Source’ folder of the Weather Processing Program (WPP) and run the WPP program. The convert program extracts and renames each weather data properly and stores them in the ‘Destination’ folder of the convert program. Copy the weather files from WPP's destination folder onto PCRANCH's 'W' folder The converted file name is named by using the Station Number, Station Name, and Starting and Ending dates. For Example:

ACT_005_Davis_05_06_2003_TO_12_19_2007.txt

The file name starts with the word ACT or AVG. which stands for Actual or Average weather. Then there is the station Id number, such as 005. Then there is the station name, such as Davis. Then there is the start date, such as 05_06_2003 (MM/DD/YYYY). Then there is the end date, such as 12_19_2007 (MM/DD/YYYY). The start and end dates are determined from the content of the weather data and not from the start and end dates you specified in the web page. There are two copies of the converted file: The first one is a tab delimited file with .TXT extension which is used by PCRANCH. The second one is a comma separated file with .CSV extension which is NOT used by PCRANCH. This file is created for your inspection and can be opened by the Excel program.

Missing Value Calculation

Daily Average Solar Radiation - Replace the R and S flag with M flag (M = Missing)
Daily Air Temperature - Replace the R, S, and Y flag with M flag (M = Missing)
Daily Average Wind Speed - Replace S, R and Y codes with M code (M=Missing)
Daily Precipitation - Replace R and S codes with M code (M=Missing)
Daily Average Relative Humidity - I do not know how to quality control this field
If the missing value is for one day, then it is replaced by interpolating between yesterday and tomorrow values. If more than one day is missing, it is replaced by the average value for that day over the entire period of weather data.

Conversion factor

Convert solar radiation from w/sq m to cal/cm2/d by multiplying it with 2.0592. Convert wind speed from m/s to km/h by multiplying it with 3.6. The temperature is already in metric system. The relative humidity is in percentage and hence do not need to be converted.

The PCRANCH Weather File Format

The weather file is a tab delimited txt file. The first line contains the column headings. Each line thereafter contains the weather data for one day. The weather file must be in date order and must cover the time period for the simulation at minimum (it may cover a longer time period). All weather fields must be supplied for every day of this period (no missing values). The weather data is always in Metric system, regardless of the system you have selected for the program.