River Runoff Correlation in Washington State

Antonia Berndt

This project examines river flow (runoff) values for various stations across Washington State. Representative runoff stations with sufficient and reliable data are displayed within their respective watershed to visualize the spatial correlation of watersheds with each other.

CyberGIS Link:

In [2]:
#Importing Modules
import geopandas as gpd
import pandas as pd
from shapely.geometry import Point
from matplotlib import pyplot as plt
import seaborn as sb

Data Source 1: Water Resource Inventory Areas (WRIA)

Downloaded from: https://geo.wa.gov/datasets/df827f607eb347d49a6cca071ce66d5e_11/explore

This data is sourced through Washington's Geospatial Open Data Portal. The shapefile provides an outline of the state and its major water resource inventory areas (i.e. watersheds). More information about how these boundaries were determined can be found here: https://geo.wa.gov/datasets/waecy::water-resource-inventory-areas-wria/about

In [4]:
#The WRIA shapefile is loaded into a geopandas dataframe as 'wria'
wria=gpd.read_file('WRIA.shp')
In [5]:
wria.describe
Out[5]:
<bound method NDFrame.describe of     WRIA_NR               WRIA_NM  WRIA_ID    WRIA_AREA_  \
0        62          Pend Oreille        1  7.897900e+05   
1        61  Upper Lake Roosevelt        2  3.688261e+05   
2         1              Nooksack        3  1.036786e+06   
3        60                Kettle        4  6.564261e+05   
4        49              Okanogan        5  1.342477e+06   
..      ...                   ...      ...           ...   
57       28    Salmon - Washougal       62  3.169310e+05   
58        7             Snohomish       24  1.222291e+06   
59        8     Cedar - Sammamish       31  4.470858e+05   
60        9      Duwamish - Green       38  3.645308e+05   
61       10      Puyallup - White       44  6.732034e+05   

                                GlobalID         created_us created_da  \
0   2e9243dc-ffb5-4f1f-adc6-e1dbc845a9ae  WAECY_Geoservices 2024-06-30   
1   f365abb0-65a3-4611-bf97-1ba0c269e808  WAECY_Geoservices 2024-06-30   
2   02195eb7-fef4-457a-93e9-ba3964124a93  WAECY_Geoservices 2024-06-30   
3   c5196e1e-6ffe-40b5-bdb5-de76fba667fd  WAECY_Geoservices 2024-06-30   
4   ea14957c-8d24-4048-b2df-171659828838  WAECY_Geoservices 2024-06-30   
..                                   ...                ...        ...   
57  2cc65a77-10cf-4970-b290-20dc368638cb  WAECY_Geoservices 2024-06-30   
58  4d2b2f14-c29f-45ce-968a-c31c8ba851e6  WAECY_Geoservices 2024-06-30   
59  2a644c95-c806-4176-9491-f68151e1a6a8  WAECY_Geoservices 2024-06-30   
60  c81f4f15-cbc1-4abd-aed1-203a7a2750e4  WAECY_Geoservices 2024-06-30   
61  33f45e09-e5d0-45aa-8ab5-e0dffb3cc2f8  WAECY_Geoservices 2024-06-30   

           last_edite last_edi_1  \
0   WAECY_Geoservices 2024-06-30   
1   WAECY_Geoservices 2024-06-30   
2   WAECY_Geoservices 2024-06-30   
3   WAECY_Geoservices 2024-06-30   
4   WAECY_Geoservices 2024-06-30   
..                ...        ...   
57  WAECY_Geoservices 2024-06-30   
58  WAECY_Geoservices 2024-06-30   
59  WAECY_Geoservices 2024-06-30   
60  WAECY_Geoservices 2024-06-30   
61  WAECY_Geoservices 2024-06-30   

                                             geometry  
0   POLYGON ((2377934.451 1352105.624, 2378017.949...  
1   POLYGON ((2225946.832 1346700.398, 2226117.091...  
2   POLYGON ((1432255.447 1293829.986, 1432278.948...  
3   POLYGON ((1962938.641 1340349.712, 1966561.488...  
4   POLYGON ((1962938.641 1340349.712, 1962914.891...  
..                                                ...  
57  POLYGON ((1116208.113 174705.049, 1116612.112 ...  
58  POLYGON ((1182734.847 1016505.859, 1186544.705...  
59  POLYGON ((1191802.044 959276.373, 1194120.94 9...  
60  POLYGON ((1160081.205 832238.291, 1163072.596 ...  
61  POLYGON ((1149967.819 729886.914, 1151446.061 ...  

[62 rows x 10 columns]>
In [6]:
ax = wria.plot()

Data Source 2: River Stream Search - Freshwater Information Network (FIN)¶

Downloaded from: https://apps.ecology.wa.gov/eim/search/SMP/RiverStreamSearch.aspx?MPLocationMPID=4

The Washington State Department of Ecology provides data for river/stream locations throughout the state in csv format. These datasets provide a large variety of information related to river flow, water quality, temperature, turbidity, and more. They also vary in the amount of time that their measurements cover. For the purpose of this project, only stations with long term and continuous runoff data (at least circa 500 flow measurements) spanning a minimum of four decades were considered. The initial selection of stations to include in this analysis was performed manually using the overview site provided here: https://apps.ecology.wa.gov/eim/search/SMP/RiverStreamSingleStationOverview.aspx?LocationUserIds=05B110&ResultType=RiverStreamOverviewList

Flow is provided in cubic feet per second (cfs), which represents the volume of water passing through a section of a stream at a particular time. Because of this, cfs can vary based on where on a river the measurement is taken. Cfs is defined by usgs.gov as "A unit expressing rates of discharge. One cubic foot per second is equal to the discharge of a stream of rectangular cross section, 1 foot wide and 1 foot deep, flowing water an average velocity of 1 foot per second." (https://water.usgs.gov/wsc/glossary.html#Cubicfeetpersecond)

When requesting data from the FIN, all watersheds were selected. However, the download portal limits the amount of data that may be requested at one time. For this reason, data was requested in two separate orders based on Monitoring Region: one for Northwest and Southwest WA, and one for Central and Eastern WA. The request was filtered further by setting the Location Status to "Active" and the Location Setting to "Long-term".

Data from these runoff stations were imported, filtered, and analyzed further within this project. A full overview of the stations that were finally selected to represent each watershed is provided below.

In [8]:
#Reading in the River Stream Results csv for eastern and western WA as pandas dataframes.
east=pd.read_csv('RiverStreamResults_2024Jul27_200373.csv') #Central & East WA
west=pd.read_csv('RiverStreamResults_2024Jul29_275611.csv') #Northwest & Southwest WA
C:\Users\anton\AppData\Local\Temp\ipykernel_16808\1576623742.py:2: DtypeWarning: Columns (6,13,15,16,19,21,24,30,31,32,33,37,38,40,43,50,52,58,59,65,83) have mixed types. Specify dtype option on import or set low_memory=False.
  east=pd.read_csv('RiverStreamResults_2024Jul27_200373.csv') #Central & East WA
C:\Users\anton\AppData\Local\Temp\ipykernel_16808\1576623742.py:3: DtypeWarning: Columns (6,21,24,43,46,50,52,58,65,67,83) have mixed types. Specify dtype option on import or set low_memory=False.
  west=pd.read_csv('RiverStreamResults_2024Jul29_275611.csv') #Northwest & Southwest WA
In [9]:
riv=pd.concat([west,east], ignore_index=True) #Concatenating West and East data into one dataframe
In [10]:
#The River Stream Location Details provides more information about each station, including a description of their location.
#River details are read in for East and West, then concatenated.
eastDetails=pd.read_csv('RiverStreamLocationDetails_2024Jul27_24.csv') #Central & East WA
westDetails=pd.read_csv('RiverStreamLocationDetails_2024Jul29_35.csv') #Northwest & Southwest WA
In [11]:
rivDetails=pd.concat([westDetails,eastDetails], ignore_index=True)
rivDetails
Out[11]:
Location_ID Location_Name Location_Setting_Description Location_Description Ecology_Facility_Site_ID Is_Location_a_Well Address City State Zip_Code ... Elevation_Accuracy Elevation_Collecton_Method Sediment_Elevation_Elevation_Reference Location_Suspect_or_Rejected_Flag Location_Suspect_Code Location_Suspect_Description Location_ID_Alias Associated_Study_ID Record_Created_On Location_System_ID
0 10A070 PUYALLUP RIVER AT MERIDIAN ST Channeled, flowing water LOCATED AT THE BRIDGE IMMEDIATELY NORTH OF PUY... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0007, AJOH0029, AMS001, AMS001, AMS001-2, ... 1/1/1753 12:00:00 AM 3063040
1 09A190 GREEN RIVER AT KANASKAT Channeled, flowing water LOCATED AT THE CUMBERLAND-PALMER ROAD BRIDGE A... NaN N NaN NaN WA NaN ... +/- 10 ft (3 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AJOH0007, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 2043040
2 09A080 GREEN RIVER AT TUKWILA Channeled, flowing water LOCATED AT THE INTERSECTION ON INTERURBAN AVEN... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0007, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 6023040
3 20B070 HOH RIVER AT DNR CAMPGROUND Channeled, flowing water LOCATED AT THE BANK IN THE DEPARTMENT OF NATUR... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 3494040
4 26B070 COWLITZ RIVER AT KELSO Channeled, flowing water LOCATED IN KELSO AT THE ALLEN (MAIN) STREET BR... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 6242320
5 05A070 STILLAGUAMISH RIVER NEAR SILVANA Channeled, flowing water LOCATED ON THE INTERSTATE 5 BRIDGE JUST NORTH ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 4560040
6 08C110 CEDAR RIVER NEAR LANDSBURG Channeled, flowing water Located 100 ft. downstream of the former Trude... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 2492040
7 27D090 EAST FORK LEWIS RIVER NEAR DOLLAR CORNER Channeled, flowing water LOCATED AT THE LEWIS RIVER BOTTOM ROAD BRIDGE,... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 3132140
8 05B110 NORTH FORK STILLAGUAMISH NEAR DARRINGTON Channeled, flowing water LOCATED .9 MILES NORTH OF HIGHWAY 530 AND WHIT... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 4181040
9 20E100 TWIN CREEK AT UPPER HOH RD BRIDGE Channeled, flowing water Hwy 101 to Upper Hoh Rd to Twin Creek bridge NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2 12/9/2010 11:03:29 AM 94635442
10 07A090 SNOHOMISH RIVER AT SNOHOMISH Channeled, flowing water LOCATED AT BRIDGE ON AVENUE D IN SNOHOMISH, TW... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 9591040
11 22A070 HUMPTULIPS RIVER NEAR HUMPTULIPS Channeled, flowing water LOCATED AT THE BRIDGE ON HIGHWAY 101, JUST SOU... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 115040
12 05A090 SOUTH FORK STILLAGUAMISH AT ARLINGTON Channeled, flowing water AT BRIDGE ON STATE HIGHWAY 530 IN ARLINGTON NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 480040
13 24F070 NASELLE RIVER NEAR NASELLE Channeled, flowing water LOCATED APPROXIMATELY TWO MILES UP THE Upper N... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1410140
14 11A070 NISQUALLY RIVER AT NISQUALLY Channeled, flowing water LOCATED AT THE BRIDGE ON OLD PACIFIC HIGHWAY, ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 3383040
15 08C070 CEDAR RIVER AT LOGAN ST/RENTON Channeled, flowing water LOCATED AT THE BRIDGE ON LOGAN STREET IN RENTO... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 5262040
16 05B070 NORTH FORK STILLAGUAMISH AT CICERO Channeled, flowing water LOCATED ON LEFT BANK UNDER BRIDGE ON STATE HIG... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 6241040
17 03A060 SKAGIT RIVER NEAR MOUNT VERNON Channeled, flowing water LOCATED ONE MILE NORTH OF MOUNT VERNON AT THE ... NaN N NaN NaN WA NaN ... +/- 3 ft (1 m) Digital elevation model (DEM) - lidar NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 6515940
18 24B090 WILLAPA RIVER NEAR WILLAPA Channeled, flowing water LOCATED AT THE BRIDGE ON BULLARD ROAD ABOUT ON... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 7275040
19 04A100 SKAGIT RIVER AT MARBLEMOUNT Channeled, flowing water LOCATED AT THE BRIDGE ON THE CASCADE RIVER ROA... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8030040
20 01A120 NOOKSACK RIVER AT NORTH CEDARVILLE Channeled, flowing water LOCATED ON HIGHWAY 542 (MOUNT BAKER HIGHWAY) A... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 9224770
21 13A060 DESCHUTES RIVER AT EAST ST BRIDGE Channeled, flowing water LOCATED AT THE BRIDGE ON E STREET, IMMEDIATELY... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8104040
22 27B070 KALAMA RIVER NEAR KALAMA Channeled, flowing water LOCATED ON THE KALAMA RIVER 2.3 MILES NE OF KA... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 102140
23 03B050 SAMISH RIVER NEAR BURLINGTON Channeled, flowing water LOCATED AT BRIDGE OVER SAMISH RIVER ON OLD HIG... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 585940
24 23A160 CHEHALIS RIVER AT DRYAD Channeled, flowing water LOCATED AT THE BRIDGE LEAVING DRYAD ON THE SOU... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 3355040
25 07C070 SKYKOMISH RIVER AT MONROE Channeled, flowing water LOCATED AT THE RAILROAD TRESTLE .5 MILES EAST ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8022040
26 23A070 CHEHALIS RIVER AT PORTER Channeled, flowing water LOCATED AT THE BRIDGE ON THE SIDE ROAD OFF US ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1435040
27 01A050 NOOKSACK RIVER AND BRENNAN Channeled, flowing water LOCATED ONE MILE WEST OF BRENNAN AT BRIDGE OVE... NaN N NaN NaN WA NaN ... +/- 40 ft (12 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 4064770
28 16A070 SKOKOMISH RIVER NEAR POTLATCH Channeled, flowing water LOCATED AT HIGHWAY 101 BRIDGE ON THE SKOKOMISH... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 2333320
29 07D130 SNOQUALMIE RIVER AT SNOQUALMIE Channeled, flowing water LOCATED AT THE BRIDGE EAST OF SNOQUALMIE ON TH... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1581320
30 05A110 SOUTH FORK STILLY NEAR GRANITE FALLS Channeled, flowing water LOCATED 1.5 MILES PAST GRANITE FALLS ON MOUNTA... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 9021040
31 16C090 DUCKABUSH RIVER NEAR BRINNON Channeled, flowing water LOCATED AT THE GS RECORDER IN THE SOUTHWEST QU... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 9054040
32 07D050 SNOQUALMIE RIVER NEAR MONROE Channeled, flowing water LOCATED AT HIGH BRIDGE AT THE SOUTHWEST CORNER... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 4432040
33 18B070 ELWHA RIVER NEAR PORT ANGELES Channeled, flowing water LOCATED AT BRIDGE ON HIGHWAY 101, 12 MILES WES... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 174040
34 07A089 Snohomish R @ Snohomish PUD Channeled, flowing water Snohomish R @ Snohomish PUD NaN N NaN NaN WA NaN ... +/- 40 ft (12 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AMS001-2 7/17/2023 3:58:24 PM 100134003
35 37A090 YAKIMA RIVER AT KIONA Channeled, flowing water LOCATED .1 MILE NORTH OF HIGHWAY 12/82 AT KION... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0007, AJOH0029, AMS001, AMS001, AMS001-2, ... 1/1/1753 12:00:00 AM 5184640
36 49B070 SIMILKAMEEN RIVER AT OROVILLE Channeled, flowing water LOCATED .2 MILES WEST OF HIGHWAY 97 AT THE BRI... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0016, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 1431740
37 57A150 SPOKANE RIVER AT STATELINE BRIDGE Channeled, flowing water LOCATED AT THE BRIDGE ON STATELINE VILLAGE ROA... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0022, AJOH0029, AMS001, AMS001, AMS001-2, ... 1/1/1753 12:00:00 AM 222740
38 34A070 PALOUSE RIVER AT HOOPER Channeled, flowing water LOCATED IN DOWNTOWN HOOPER NEAR TRAIN TRACKS A... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0028, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 8483640
39 54A120 SPOKANE RIVER AT RIVERSIDE STATE PARK Channeled, flowing water LOCATED IN SPOKANE AT RIVERSIDE STATE PARK ON ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0028, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 3351740
40 48A140 METHOW RIVER AT TWISP Channeled, flowing water THIS STATION IS LOCATED ON THE DOWNSTREAM SIDE... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 3180740
41 53A070 COLUMBIA RIVER AT GRAND COULEE Channeled, flowing water LOCATED AT THE COULEE DAM BRIDGE .5 MILES BELO... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 4485021
42 36A070 COLUMBIA RIVER NEAR VERNITA Channeled, flowing water LOCATED ON STATE HIGHWAY 24 AT THE VERNITA BRI... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8175021
43 35B060 TUANNON RIVER AT POWERS Channeled, flowing water LOCATED .2 MILES SOUTHEAST OF HIGHWAY 261, 1.5... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 364640
44 49A190 OKANOGAN AT OROVILLE Channeled, flowing water LOCATED AT THE BRIDGE ON CHERRY (BRIDGE ST.) S... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1021740
45 60A070 KETTLE RIVER NEAR BARSTOW Channeled, flowing water LOCATED 10.9 MILES FROM THE MOUTH OF THE KETTL... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1242740
46 46A070 ENTIAT RIVER NEAR ENTIAT Channeled, flowing water LOCATED AT A PRIVATE BRIDGE 1.2 MILES FROM HIG... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 7060740
47 49A070 OKANOGAN RIVER AT MALOTT Channeled, flowing water LOCATED AT THE MALOTT BRIDGE CROSSING THE OKAN... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8590740
48 34B110 SOUTH PALOUSE RIVER AT PULLMAN Channeled, flowing water LOCATED AT THE BRIDGE ON STATE STREET ONE BLOC... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 7103702
49 41A070 CRAB CREEK NEAR BEVERLY Channeled, flowing water LOCATED 6 MILES FROM THE MOUTH OF CRAB CREEK A... NaN N NaN NaN WA NaN ... +/- 10 ft (3 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8355640
50 45A110 WENATCHEE RIVER NEAR LEAVENWORTH Channeled, flowing water LOCATED AT THE UPPER END OF TUMWATER CANYON ON... NaN N NaN NaN WA NaN ... +/- 10 ft (3 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 8010740
51 56A070 HANGMAN CREEK AT MOUTH Channeled, flowing water LOCATED AT THE MOUTH OF HANGMAN CREEK AT RIVER... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 1102740
52 45A070 WENATCHEE RIVER AT WENATCHEE Channeled, flowing water LOCATED 1.1 MILES FROM THE MOUTH OF THE WENATC... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 4295640
53 37A205 YAKIMA RIVER AT NOB HILL Channeled, flowing water HIGHWAY 24 BRIDGE just east of Yakima. Nob Hi... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001D, A... 1/1/1753 12:00:00 AM 6494640
54 48A075 METHOW RIVER NR PATEROS AT METAL BRIDGE Channeled, flowing water From Twisp: Go to Hwy 20 and head southeast. ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN NaN AMS001, AMS001, AMS001-2, AMS001-2, AMS001E, A... 6/10/2009 1:49:48 PM 29056129
55 37L050 Corral Cr @ Old inland Hwy Channeled, flowing water Corral Cr @ Old inland Hwy NaN N NaN NaN WA NaN ... +/- 10 ft (3 m) Digital elevation model (DEM) - source unspeci... NaN NaN NaN NaN NaN AMS001, AMS001-2 11/27/2018 4:29:41 PM 100084846
56 34A170 PALOUSE RIVER AT PALOUSE (BRIDGE ST) Channeled, flowing water LOCATED AT THE HWY 27 BRIDGE (BRIDGE ST) IN PA... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN 34PAL120.3 AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 5404640
57 61A070 COLUMBIA RIVER AT NORTHPORT Channeled, flowing water LOCATED AT THE BRIDGE CROSSING THE COLUMBIA RI... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN COLUMBIARIVER AJOH0029, AMS001, AMS001, AMS001-2, AMS001-2, ... 1/1/1753 12:00:00 AM 8083320
58 32A070 WALLA WALLA RIVER NEAR TOUCHET Channeled, flowing water LOCATED AT A PRIVATE BRIDGE THREE RIVER MILES ... NaN N NaN NaN WA NaN ... NaN NaN NaN NaN NaN NaN WALLAWALLARIVER AMS001, AMS001, AMS001-2, AMS001-2, AMS001B, A... 1/1/1753 12:00:00 AM 2053640

59 rows × 45 columns

In [12]:
#The riv dataset includes a variety of measurements. For this project, we filter out all data except that for river flow.
riv=riv[riv['Result_Parameter_Name']=='Flow'] 
In [13]:
#Creating a 'stations' dataframe. This drops duplicates from riv to show the Location_ID, Location Name and Lat/Lon of the individual stations.
stations=riv[['Location_ID','Location_Name','Calculated_Latitude_Decimal_Degrees_NAD83HARN','Calculated_Longitude_Decimal_Degrees_NAD83HARN']].drop_duplicates()
stations=stations.sort_values(by='Location_ID')
stations
Out[13]:
Location_ID Location_Name Calculated_Latitude_Decimal_Degrees_NAD83HARN Calculated_Longitude_Decimal_Degrees_NAD83HARN
78 01A050 NOOKSACK RIVER AND BRENNAN 48.818889 -122.580000
360 01A120 NOOKSACK R @ NO CEDARVILLE 48.841670 -122.293050
66157 01A120 NOOKSACK RIVER AT NORTH CEDARVILLE 48.841670 -122.293050
45 03A060 SKAGIT RIVER NEAR MOUNT VERNON 48.444833 -122.335451
133 03B050 SAMISH RIVER NEAR BURLINGTON 48.545823 -122.338124
17 04A100 SKAGIT RIVER AT MARBLEMOUNT 48.526230 -121.429020
335 05A070 STILLAGUAMISH RIVER NEAR SILVANA 48.196782 -122.210067
339 05A090 SOUTH FORK STILLAGUAMISH AT ARLINGTON 48.200660 -122.119030
23 05A110 S. FORK STILLY NEAR GRANITE FALLS 48.103160 -121.953190
66161 05A110 SOUTH FORK STILLY NEAR GRANITE FALLS 48.103160 -121.953190
66173 05B070 NORTH FORK STILLAGUAMISH AT CICERO 48.267880 -122.013470
343 05B070 NO. FORK STILLAGUAMISH AT CICERO 48.267880 -122.013470
868 05B110 NORTH FORK STILLAGUAMISH NEAR DARRINGTON 48.280286 -121.702500
51 07A090 SNOHOMISH RIVER AT SNOHOMISH 47.910370 -122.099020
282 07C070 SKYKOMISH RIVER AT MONROE 47.846318 -121.970651
536 07D050 SNOQUALMIE RIVER NEAR MONROE 47.803727 -122.002445
277 07D130 SNOQUALMIE RIVER AT SNOQUALMIE 47.527600 -121.812330
12 08C070 CEDAR RIVER AT LOGAN ST/RENTON 47.485655 -122.209010
5 08C110 CEDAR RIVER NEAR LANDSBURG 47.391045 -121.920663
1616 09A080 GREEN RIVER AT TUKWILA 47.464270 -122.248180
36 09A190 GREEN RIVER AT KANASKAT 47.319274 -121.893737
265 10A070 PUYALLUP RIVER AT MERIDIAN ST 47.202600 -122.293730
72 11A070 NISQUALLY RIVER AT NISQUALLY 47.061760 -122.696240
187 13A060 DESCHUTES RIVER AT EAST ST BRIDGE 47.011698 -122.903513
98 16A070 SKOKOMISH RIVER NEAR POTLATCH 47.310000 -123.176640
973 16C090 DUCKABUSH RIVER NEAR BRINNON 47.683980 -123.011550
213 18B070 ELWHA RIVER NEAR PORT ANGELES 48.065400 -123.577700
303 20B070 HOH RIVER AT DNR CAMPGROUND 47.806750 -124.251030
106 22A070 HUMPTULIPS RIVER NEAR HUMPTULIPS 47.229810 -123.961840
3 23A070 CHEHALIS RIVER AT PORTER 46.939180 -123.313990
86 23A160 CHEHALIS RIVER AT DRYAD 46.631100 -123.250990
81 24B090 WILLAPA RIVER NEAR WILLAPA 46.649820 -123.654050
147 24F070 NASELLE RIVER NEAR NASELLE 46.372880 -123.746810
67 26B070 COWLITZ RIVER AT KELSO 46.145390 -122.914280
69 27B070 KALAMA RIVER NEAR KALAMA 46.047318 -122.837526
182 27D090 EAST FORK LEWIS RIVER NEAR DOLLAR CORNER 45.814200 -122.591700
275612 32A070 WALLA WALLA RIVER NEAR TOUCHET 46.037630 -118.766380
275674 34A070 PALOUSE RIVER AT HOOPER 46.759038 -118.148016
275822 34A170 PALOUSE RIVER AT PALOUSE (BRIDGE ST) 46.909110 -117.076550
275680 34B110 SOUTH PALOUSE RIVER AT PULLMAN 46.732476 -117.180949
275671 35B060 TUANNON RIVER AT POWERS 46.538199 -118.156070
275627 36A070 COLUMBIA RIVER NEAR VERNITA 46.641520 -119.731705
275628 37A090 YAKIMA RIVER AT KIONA 46.253467 -119.478078
275706 37A205 YAKIMA RIVER AT NOB HILL 46.581500 -120.461700
275646 41A070 CRAB CREEK NEAR BEVERLY 46.829917 -119.830889
275660 45A070 WENATCHEE RIVER AT WENATCHEE 47.458740 -120.336460
275665 45A110 WENATCHEE RIVER NEAR LEAVENWORTH 47.676369 -120.734018
275769 46A070 ENTIAT RIVER NEAR ENTIAT 47.663180 -120.250630
323343 48A075 METHOW RIVER NR PATEROS AT METAL BRIDGE 48.076141 -119.969824
275756 48A140 METHOW RIVER AT TWISP 48.359370 -120.114580
275746 49A070 OKANOGAN RIVER AT MALOTT 48.281260 -119.704500
275736 49A190 OKANOGAN AT OROVILLE 48.938770 -119.427840
275730 49B070 SIMILKAMEEN RIVER AT OROVILLE 48.934793 -119.442040
275776 53A070 COLUMBIA RIVER AT GRAND COULEE 47.965430 -118.982800
275619 54A120 SPOKANE RIVER AT RIVERSIDE STATE PARK 47.696560 -117.497720
275687 56A070 HANGMAN CREEK AT MOUTH 47.654613 -117.454380
275649 57A150 SPOKANE RIVER AT STATELINE BRIDGE 47.698511 -117.044644
275955 60A070 KETTLE RIVER NEAR BARSTOW 48.784630 -118.125270
275793 61A070 COLUMBIA RIVER AT NORTHPORT 48.922411 -117.776650
In [14]:
#Based on a manual audit within the FIN portal, certain stations did not meet criteria for long-term flow data. These are dropped here.
#More details regarding how these were selected can be found in the data description above and in the project report.
to_drop=['03B050','05A090','05A110','05B110','07C070','07D050','09A080','16C090','24F070','27D090','34A170','37A205','48A075','49A070']
stations=stations[~stations['Location_ID'].isin(to_drop)] #~ flips a True statement to False, meaning we keep any rows that are not in the to_drop list.
stations=stations.drop([360,343]) #These stations were missed in the previous drop_duplicates function.
stations
Out[14]:
Location_ID Location_Name Calculated_Latitude_Decimal_Degrees_NAD83HARN Calculated_Longitude_Decimal_Degrees_NAD83HARN
78 01A050 NOOKSACK RIVER AND BRENNAN 48.818889 -122.580000
66157 01A120 NOOKSACK RIVER AT NORTH CEDARVILLE 48.841670 -122.293050
45 03A060 SKAGIT RIVER NEAR MOUNT VERNON 48.444833 -122.335451
17 04A100 SKAGIT RIVER AT MARBLEMOUNT 48.526230 -121.429020
335 05A070 STILLAGUAMISH RIVER NEAR SILVANA 48.196782 -122.210067
66173 05B070 NORTH FORK STILLAGUAMISH AT CICERO 48.267880 -122.013470
51 07A090 SNOHOMISH RIVER AT SNOHOMISH 47.910370 -122.099020
277 07D130 SNOQUALMIE RIVER AT SNOQUALMIE 47.527600 -121.812330
12 08C070 CEDAR RIVER AT LOGAN ST/RENTON 47.485655 -122.209010
5 08C110 CEDAR RIVER NEAR LANDSBURG 47.391045 -121.920663
36 09A190 GREEN RIVER AT KANASKAT 47.319274 -121.893737
265 10A070 PUYALLUP RIVER AT MERIDIAN ST 47.202600 -122.293730
72 11A070 NISQUALLY RIVER AT NISQUALLY 47.061760 -122.696240
187 13A060 DESCHUTES RIVER AT EAST ST BRIDGE 47.011698 -122.903513
98 16A070 SKOKOMISH RIVER NEAR POTLATCH 47.310000 -123.176640
213 18B070 ELWHA RIVER NEAR PORT ANGELES 48.065400 -123.577700
303 20B070 HOH RIVER AT DNR CAMPGROUND 47.806750 -124.251030
106 22A070 HUMPTULIPS RIVER NEAR HUMPTULIPS 47.229810 -123.961840
3 23A070 CHEHALIS RIVER AT PORTER 46.939180 -123.313990
86 23A160 CHEHALIS RIVER AT DRYAD 46.631100 -123.250990
81 24B090 WILLAPA RIVER NEAR WILLAPA 46.649820 -123.654050
67 26B070 COWLITZ RIVER AT KELSO 46.145390 -122.914280
69 27B070 KALAMA RIVER NEAR KALAMA 46.047318 -122.837526
275612 32A070 WALLA WALLA RIVER NEAR TOUCHET 46.037630 -118.766380
275674 34A070 PALOUSE RIVER AT HOOPER 46.759038 -118.148016
275680 34B110 SOUTH PALOUSE RIVER AT PULLMAN 46.732476 -117.180949
275671 35B060 TUANNON RIVER AT POWERS 46.538199 -118.156070
275627 36A070 COLUMBIA RIVER NEAR VERNITA 46.641520 -119.731705
275628 37A090 YAKIMA RIVER AT KIONA 46.253467 -119.478078
275646 41A070 CRAB CREEK NEAR BEVERLY 46.829917 -119.830889
275660 45A070 WENATCHEE RIVER AT WENATCHEE 47.458740 -120.336460
275665 45A110 WENATCHEE RIVER NEAR LEAVENWORTH 47.676369 -120.734018
275769 46A070 ENTIAT RIVER NEAR ENTIAT 47.663180 -120.250630
275756 48A140 METHOW RIVER AT TWISP 48.359370 -120.114580
275736 49A190 OKANOGAN AT OROVILLE 48.938770 -119.427840
275730 49B070 SIMILKAMEEN RIVER AT OROVILLE 48.934793 -119.442040
275776 53A070 COLUMBIA RIVER AT GRAND COULEE 47.965430 -118.982800
275619 54A120 SPOKANE RIVER AT RIVERSIDE STATE PARK 47.696560 -117.497720
275687 56A070 HANGMAN CREEK AT MOUTH 47.654613 -117.454380
275649 57A150 SPOKANE RIVER AT STATELINE BRIDGE 47.698511 -117.044644
275955 60A070 KETTLE RIVER NEAR BARSTOW 48.784630 -118.125270
275793 61A070 COLUMBIA RIVER AT NORTHPORT 48.922411 -117.776650
In [15]:
print ('Total number of stations: ' + str(len(stations)))
Total number of stations: 42
In [16]:
#The stations dataset was transformed into a geopandas dataframe based on their latitude and longitude.
stations=gpd.GeoDataFrame(stations, geometry=gpd.points_from_xy(stations.Calculated_Longitude_Decimal_Degrees_NAD83HARN, 
                                                           stations.Calculated_Latitude_Decimal_Degrees_NAD83HARN))
In [17]:
#The sortdata function is defined here. This prepares the data in the riv dataframe for analysis. 
def sortdata(loc):
    stations=riv[riv['Location_ID']==loc] #The station is defined by Location ID and selected from the riv dataframe
    stations=stations[['Field_Collection_Start_Date','Result_Value']]
    #Only the start date and measurement result of the measurement are of interest. Almost all measurements start and end on the same day
    stations['Field_Collection_Start_Date']=pd.to_datetime(stations['Field_Collection_Start_Date']) #Start date data is transformed to datetime type
    stations=stations.sort_values(by='Field_Collection_Start_Date') 
    stations=stations.set_index('Field_Collection_Start_Date') #Measurements are sorted chronologically and date is set as the index
    stations=stations.rename(columns={'Result_Value':str(loc)}) #The Result column is renamed based on the location ID
    stations=stations.resample('ME').mean() #Most stations only have one or two monthly values. 
    #The resample function groups measurements by month to determine the monthly mean. This allows for easier comparison with monthly runoff at other stations
    return stations
In [18]:
#This for loop runs each station in the stations list through the sort data function
dict={} #All flow dataframes for each station will be collected within this dictionary
for x in list(stations['Location_ID']):
    dict[f's{x}'] = sortdata(x)
In [19]:
#The coordinate reference systems for both geopandas dataframes are set to WGS84 (4326) so they can be plotted together.
stations=stations.set_crs('4326')
wria=wria.to_crs('4326')
In [20]:
map = wria.plot(figsize=(16, 12), label='WRIA_NM')
stations.plot(ax=map, marker='+', color='white',markersize=80)
for x, y, label in zip(wria.geometry.centroid.x, wria.geometry.centroid.y, wria['WRIA_NM']):
    map.annotate(label, xy=(x, y), fontsize=8, ha='center') #Plotting annotations for each WRIA
plt.show()
#This plot shows the locations of runoff measurement stations throughout WA with white markers.
C:\Users\anton\AppData\Local\Temp\ipykernel_16808\3040242645.py:3: UserWarning: Geometry is in a geographic CRS. Results from 'centroid' are likely incorrect. Use 'GeoSeries.to_crs()' to re-project geometries to a projected CRS before this operation.

  for x, y, label in zip(wria.geometry.centroid.x, wria.geometry.centroid.y, wria['WRIA_NM']):

The above plot shows the selected stations with sufficient data and their placement within Washington's WRIA. We see that some watersheds do not have any measurements stations, while others have multiple.

Below, the runoff timeseries of several stations are plotted along with other's within the same watershed. This serves two purposes.

  • We can select one representative station for each watershed for further analysis. This selection is primarily based on which station has longer and greater runoff data as this can show more variation and is likely the most representative of the area.
  • The runoff time series provides a better understanding of what our runoff data looks like. We can visually identify the seasonal cycles in runoff and correlation with runoff at nearby stations. For almost all stations (including those not shown in these examples) we can rely on continuous data from the late 1970s onwards.
In [22]:
plt.figure(figsize=(12,4))
dict['s07A090']['07A090'].plot(label='Snohomish River at Snohomish')
dict['s07D130']['07D130'].plot(label='Snoqualmie River at Snoqualmie')
plt.legend()
plt.ylabel('cfs')
plt.title('Snohomish')
#Selecting the station at Snohomish to represent runoff as Snoqualmie River has lower runoff values and more gaps.
Out[22]:
Text(0.5, 1.0, 'Snohomish')
In [23]:
plt.figure(figsize=(12,4))
dict['s23A070']['23A070'].plot(label='at Porter')
dict['s23A160']['23A160'].plot(label='at Dryad')
plt.legend()
plt.ylabel('cfs')
plt.title('Upper Chehalis')
#Selecting the runoff at Porter to represent the Upper Chehalis watershed as it has a longer runoff series than that at Dryad.
Out[23]:
Text(0.5, 1.0, 'Upper Chehalis')
In [24]:
plt.figure(figsize=(12,4))
dict['s45A070']['45A070'].plot(label='at Wenatchee')
dict['s45A110']['45A110'].plot(label='near Leavenworth')
plt.legend()
plt.ylabel('cfs')
plt.title('Wenatchee')
#The runoff stations for the Wenatchee River do show impressive visual correlation with each other. 
#We can assume that the extreme runoff value at Leavenworth is likely erroneous; therefore, the Wenatchee station may be more reliable.
Out[24]:
Text(0.5, 1.0, 'Wenatchee')
In [25]:
#For all other WRIAs that had more than one station, these were compared in a similar fashion to select one representative for that WRIA.
#The remaining stations are dropped here
to_drop=['01A050','05B070','07D130','08C110','23A160','34B110','45A110','49A190']
stations=stations[~stations['Location_ID'].isin(to_drop)] 
stations
Out[25]:
Location_ID Location_Name Calculated_Latitude_Decimal_Degrees_NAD83HARN Calculated_Longitude_Decimal_Degrees_NAD83HARN geometry
66157 01A120 NOOKSACK RIVER AT NORTH CEDARVILLE 48.841670 -122.293050 POINT (-122.29305 48.84167)
45 03A060 SKAGIT RIVER NEAR MOUNT VERNON 48.444833 -122.335451 POINT (-122.33545 48.44483)
17 04A100 SKAGIT RIVER AT MARBLEMOUNT 48.526230 -121.429020 POINT (-121.42902 48.52623)
335 05A070 STILLAGUAMISH RIVER NEAR SILVANA 48.196782 -122.210067 POINT (-122.21007 48.19678)
51 07A090 SNOHOMISH RIVER AT SNOHOMISH 47.910370 -122.099020 POINT (-122.09902 47.91037)
12 08C070 CEDAR RIVER AT LOGAN ST/RENTON 47.485655 -122.209010 POINT (-122.20901 47.48566)
36 09A190 GREEN RIVER AT KANASKAT 47.319274 -121.893737 POINT (-121.89374 47.31927)
265 10A070 PUYALLUP RIVER AT MERIDIAN ST 47.202600 -122.293730 POINT (-122.29373 47.2026)
72 11A070 NISQUALLY RIVER AT NISQUALLY 47.061760 -122.696240 POINT (-122.69624 47.06176)
187 13A060 DESCHUTES RIVER AT EAST ST BRIDGE 47.011698 -122.903513 POINT (-122.90351 47.0117)
98 16A070 SKOKOMISH RIVER NEAR POTLATCH 47.310000 -123.176640 POINT (-123.17664 47.31)
213 18B070 ELWHA RIVER NEAR PORT ANGELES 48.065400 -123.577700 POINT (-123.5777 48.0654)
303 20B070 HOH RIVER AT DNR CAMPGROUND 47.806750 -124.251030 POINT (-124.25103 47.80675)
106 22A070 HUMPTULIPS RIVER NEAR HUMPTULIPS 47.229810 -123.961840 POINT (-123.96184 47.22981)
3 23A070 CHEHALIS RIVER AT PORTER 46.939180 -123.313990 POINT (-123.31399 46.93918)
81 24B090 WILLAPA RIVER NEAR WILLAPA 46.649820 -123.654050 POINT (-123.65405 46.64982)
67 26B070 COWLITZ RIVER AT KELSO 46.145390 -122.914280 POINT (-122.91428 46.14539)
69 27B070 KALAMA RIVER NEAR KALAMA 46.047318 -122.837526 POINT (-122.83753 46.04732)
275612 32A070 WALLA WALLA RIVER NEAR TOUCHET 46.037630 -118.766380 POINT (-118.76638 46.03763)
275674 34A070 PALOUSE RIVER AT HOOPER 46.759038 -118.148016 POINT (-118.14802 46.75904)
275671 35B060 TUANNON RIVER AT POWERS 46.538199 -118.156070 POINT (-118.15607 46.5382)
275627 36A070 COLUMBIA RIVER NEAR VERNITA 46.641520 -119.731705 POINT (-119.73171 46.64152)
275628 37A090 YAKIMA RIVER AT KIONA 46.253467 -119.478078 POINT (-119.47808 46.25347)
275646 41A070 CRAB CREEK NEAR BEVERLY 46.829917 -119.830889 POINT (-119.83089 46.82992)
275660 45A070 WENATCHEE RIVER AT WENATCHEE 47.458740 -120.336460 POINT (-120.33646 47.45874)
275769 46A070 ENTIAT RIVER NEAR ENTIAT 47.663180 -120.250630 POINT (-120.25063 47.66318)
275756 48A140 METHOW RIVER AT TWISP 48.359370 -120.114580 POINT (-120.11458 48.35937)
275730 49B070 SIMILKAMEEN RIVER AT OROVILLE 48.934793 -119.442040 POINT (-119.44204 48.93479)
275776 53A070 COLUMBIA RIVER AT GRAND COULEE 47.965430 -118.982800 POINT (-118.9828 47.96543)
275619 54A120 SPOKANE RIVER AT RIVERSIDE STATE PARK 47.696560 -117.497720 POINT (-117.49772 47.69656)
275687 56A070 HANGMAN CREEK AT MOUTH 47.654613 -117.454380 POINT (-117.45438 47.65461)
275649 57A150 SPOKANE RIVER AT STATELINE BRIDGE 47.698511 -117.044644 POINT (-117.04464 47.69851)
275955 60A070 KETTLE RIVER NEAR BARSTOW 48.784630 -118.125270 POINT (-118.12527 48.78463)
275793 61A070 COLUMBIA RIVER AT NORTHPORT 48.922411 -117.776650 POINT (-117.77665 48.92241)

Representative Runoff Stations

Nooksack

01A120 at North Cedarville

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=4064770

Lower Skagit-Samish

03A060 Skagit River near Mt Vernon

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=6515940

Upper Skagit

04A100 Skagit River at Marblemount

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8030040

Stillaguamish

05A070 Stillaguamish River near Silvana

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=4560040

Snohomish

07A090 Snohomish at Snohomish

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=9591040

Cedar-Sammamish

08C070 Cedar River at Logan St/Renton

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=5262040

Duwamish-Green

09A190 Green River at Kanaskat

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=2043040

Puyallup-White

10A070 Puyallup River at Meridian St

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=3063040

Nisqually

11A070 Nisqually River at Nisqually

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=3383040

Deschutes

13A060 Deschutes River at East St Bridge

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8104040

Skokomish-Dosewallips

16A070 Skokomish River near Potlach

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=2333320

Elwah-Dungeness

18B070 Elwah River near Port Angeles

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=174040

Soleduck-Hoh

20B070 Hoh River at DNR Campground

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=3494040

Lower Chehalis

22A070 Humptulips River near Humptulips

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=115040

Upper Chehalis

23A070 Chehalis river at Porter

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=1435040

Willipa

24B090 Willapa River near

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=7275040

Cowlitz

26B070 Cowlitz River at Kelso

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=6242320

Lewis

27B070 Kalama River near Kalama

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=102140

Walla Walla

32A070 Walla Walla River near Touchet

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=2053640

Palouse

34A070 Palouse River at Hooper

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8483640

Middle Snake

35B060 Tuannon River at Powers

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=364640

Alkali-Squilchuck

36A070 Columbia River near Vernita

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8175021

Lower Yakima

37A090 Yakima River at Kiona

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=5184640

Lower Crab

41A070 Crab Creek near Beverly

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8355640

Wenatchee

45A070 Wenatchee river at Wenatchee

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=4295640

Entiat

46A070 Entiat River near Entiat

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=7060740

Methow

48A140 Methow River at Twisp

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=3180740

Okanogan

49B070 Similkameen River at Oroville

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=1431740

Grand Coulee

53A070 Columbia River at Grand Coulee

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=4485021

Lower Spokane

54A120 Spokane River at Riverside State Park

image.png

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=3351740

Hangman

56A070 Hangman Creek at Mouth

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=1102740

Middle Spokane

57A150 Spokane River at Stateline Bridge

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=222740

Kettle

60A070 Kettle River near Barstow

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=1242740

Upper Lake Roosevelt

61A070 Columbia River at Northport

https://apps.ecology.wa.gov/eim/search/Detail/Detail.aspx?DetailType=Location&SystemStationId=8083320

No station provides enough data to represent these WRIAs:
  • San Juan
  • Chambers-Clover
  • Quilcene Snow
  • Lyre-Hoko
  • Queets-Quinault
  • Grays-Elochoman
  • Salmon-Washougal
  • Wind-White Salmon
  • Klickitat
  • Rock Glade
  • Lower Snake
  • Esquatzel-Coulee
  • Lower Yakima
  • Naches
  • Upper Crab-Wilson
  • Moses-Coulee
  • Chelan
  • Foster
  • Nespelem
  • Sanpoil
  • Lower Lake Roosevelt
  • Middle Lake Roosevelt
  • Colville
  • Pend-Oreille

Pictures are sourced via this search function: https://apps.ecology.wa.gov/eim/search/SMP/RiverStreamSingleStationOverview.aspx?FocusTab=True&ResultType=RiverStreamOverviewList&RiverStreamSearchResults&LocationUserIds=05B110&LocationUserIdSearchType=Equals&LocationUserIDAliasSearchFlag=True

In [28]:
#The sortdata function is run again on all remaining stations for further analysis
dict={}
for x in list(stations['Location_ID']):
    dict[f's{x}'] = sortdata(x)
In [29]:
print ('Total number of stations: ' + str(len(stations)))
Total number of stations: 34

Correlation Analysis

In [31]:
dict
#In order to run a correlation matrix among all stations in the dictionary, their dataframes need to be concatenated.
Out[31]:
{'s01A120':                              01A120
 Field_Collection_Start_Date        
 1959-07-31                   4000.0
 1959-08-31                      NaN
 1959-09-30                      NaN
 1959-10-31                      NaN
 1959-11-30                   9617.0
 ...                             ...
 2019-05-31                     14.0
 2019-06-30                      NaN
 2019-07-31                     13.0
 2019-08-31                     18.0
 2019-09-30                     11.0
 
 [723 rows x 1 columns],
 's03A060':                               03A060
 Field_Collection_Start_Date         
 1947-09-30                    6360.0
 1947-10-31                       NaN
 1947-11-30                       NaN
 1947-12-31                       NaN
 1948-01-31                       NaN
 ...                              ...
 2019-05-31                   12300.0
 2019-06-30                   17400.0
 2019-07-31                    8510.0
 2019-08-31                    7430.0
 2019-09-30                   10500.0
 
 [865 rows x 1 columns],
 's04A100':                               04A100
 Field_Collection_Start_Date         
 1959-07-31                   11700.0
 1959-08-31                    4320.0
 1959-09-30                    5990.0
 1959-10-31                   11600.0
 1959-11-30                    6950.0
 ...                              ...
 2019-05-31                    5440.0
 2019-06-30                    5650.0
 2019-07-31                    3130.0
 2019-08-31                    2750.0
 2019-09-30                    4730.0
 
 [723 rows x 1 columns],
 's05A070':                              05A070
 Field_Collection_Start_Date        
 1971-07-31                   3510.0
 1971-08-31                   1165.0
 1971-09-30                   3680.0
 1971-10-31                      NaN
 1971-11-30                      NaN
 ...                             ...
 2018-05-31                   3050.0
 2018-06-30                   2260.0
 2018-07-31                    956.0
 2018-08-31                    390.0
 2018-09-30                   1340.0
 
 [567 rows x 1 columns],
 's07A090':                               07A090
 Field_Collection_Start_Date         
 1959-12-31                   31020.0
 1960-01-31                       NaN
 1960-02-29                       NaN
 1960-03-31                       NaN
 1960-04-30                   14680.0
 ...                              ...
 2019-05-31                    8400.0
 2019-06-30                    6960.0
 2019-07-31                    2710.0
 2019-08-31                    1930.0
 2019-09-30                    4100.0
 
 [718 rows x 1 columns],
 's08C070':                              08C070
 Field_Collection_Start_Date        
 1959-07-31                    325.0
 1959-08-31                     80.0
 1959-09-30                    740.0
 1959-10-31                    972.0
 1959-11-30                   1920.0
 ...                             ...
 2019-05-31                    374.0
 2019-06-30                    338.0
 2019-07-31                      NaN
 2019-08-31                    338.0
 2019-09-30                    206.0
 
 [723 rows x 1 columns],
 's09A190':                              09A190
 Field_Collection_Start_Date        
 1959-07-31                    554.0
 1959-08-31                    205.0
 1959-09-30                    802.0
 1959-10-31                   1450.0
 1959-11-30                   1740.0
 ...                             ...
 2018-05-31                    898.0
 2018-06-30                    242.0
 2018-07-31                    158.0
 2018-08-31                    171.0
 2018-09-30                    192.0
 
 [711 rows x 1 columns],
 's10A070':                              10A070
 Field_Collection_Start_Date        
 1971-07-31                   5805.0
 1971-08-31                   3230.0
 1971-09-30                   1925.0
 1971-10-31                      NaN
 1971-11-30                      NaN
 ...                             ...
 2019-05-31                   3000.0
 2019-06-30                   3180.0
 2019-07-31                   1860.0
 2019-08-31                   2050.0
 2019-09-30                   1630.0
 
 [579 rows x 1 columns],
 's11A070':                              11A070
 Field_Collection_Start_Date        
 1972-10-31                   1350.0
 1972-11-30                   1690.0
 1972-12-31                   3175.0
 1973-01-31                   3135.0
 1973-02-28                   2640.0
 ...                             ...
 2019-03-31                    641.0
 2019-04-30                   1110.0
 2019-05-31                    641.0
 2019-06-30                    534.0
 2019-07-31                    540.0
 
 [562 rows x 1 columns],
 's13A060':                              13A060
 Field_Collection_Start_Date        
 1977-10-31                    118.0
 1977-11-30                   1230.0
 1977-12-31                   1300.0
 1978-01-31                    952.0
 1978-02-28                    574.0
 ...                             ...
 2019-05-31                    178.0
 2019-06-30                    102.0
 2019-07-31                    117.0
 2019-08-31                      NaN
 2019-09-30                     81.0
 
 [504 rows x 1 columns],
 's16A070':                              16A070
 Field_Collection_Start_Date        
 1960-08-31                    230.0
 1960-09-30                    250.0
 1960-10-31                    190.0
 1960-11-30                    805.0
 1960-12-31                   1130.0
 ...                             ...
 2019-04-30                      NaN
 2019-05-31                    521.0
 2019-06-30                    338.0
 2019-07-31                    223.0
 2019-08-31                    196.0
 
 [709 rows x 1 columns],
 's18B070':                              18B070
 Field_Collection_Start_Date        
 1959-07-31                   1700.0
 1959-08-31                    704.0
 1959-09-30                   1280.0
 1959-10-31                    616.0
 1959-11-30                   6500.0
 ...                             ...
 2019-05-31                   1210.0
 2019-06-30                    793.0
 2019-07-31                    466.0
 2019-08-31                    321.0
 2019-09-30                    416.0
 
 [723 rows x 1 columns],
 's20B070':                              20B070
 Field_Collection_Start_Date        
 1960-07-31                   1680.0
 1960-08-31                   1130.0
 1960-09-30                    845.0
 1960-10-31                   1060.0
 1960-11-30                   1850.0
 ...                             ...
 2019-04-30                      NaN
 2019-05-31                   1340.0
 2019-06-30                    791.0
 2019-07-31                      NaN
 2019-08-31                    666.0
 
 [710 rows x 1 columns],
 's22A070':                              22A070
 Field_Collection_Start_Date        
 1959-07-31                    385.0
 1959-08-31                    169.0
 1959-09-30                   2540.0
 1959-10-31                   1510.0
 1959-11-30                   2120.0
 ...                             ...
 2018-05-31                    340.0
 2018-06-30                    220.0
 2018-07-31                    178.0
 2018-08-31                    123.0
 2018-09-30                   1180.0
 
 [711 rows x 1 columns],
 's23A070':                                   23A070
 Field_Collection_Start_Date             
 1959-07-31                    618.000000
 1959-08-31                    338.500000
 1959-09-30                   1148.666667
 1959-10-31                   1972.000000
 1959-11-30                   9113.000000
 ...                                  ...
 2019-04-30                   2590.000000
 2019-05-31                           NaN
 2019-06-30                    551.000000
 2019-07-31                           NaN
 2019-08-31                    315.000000
 
 [722 rows x 1 columns],
 's24B090':                              24B090
 Field_Collection_Start_Date        
 1970-11-30                    532.0
 1970-12-31                   1340.0
 1971-01-31                   1814.5
 1971-02-28                   1090.0
 1971-03-31                   1190.0
 ...                             ...
 2019-03-31                    285.0
 2019-04-30                      NaN
 2019-05-31                    145.0
 2019-06-30                     60.0
 2019-07-31                     48.0
 
 [585 rows x 1 columns],
 's26B070':                              26B070
 Field_Collection_Start_Date        
 1966-07-31                   9000.0
 1966-08-31                   3280.0
 1966-09-30                   1910.0
 1966-10-31                      NaN
 1966-11-30                      NaN
 ...                             ...
 2019-05-31                      NaN
 2019-06-30                      NaN
 2019-07-31                      NaN
 2019-08-31                   3270.0
 2019-09-30                   4660.0
 
 [639 rows x 1 columns],
 's27B070':                              27B070
 Field_Collection_Start_Date        
 1971-10-31                   1064.0
 1971-11-30                   3285.0
 1971-12-31                   2840.0
 1972-01-31                   1475.0
 1972-02-29                   2285.0
 ...                             ...
 2018-05-31                    266.0
 2018-06-30                    145.0
 2018-07-31                    105.0
 2018-08-31                     82.0
 2018-09-30                    100.0
 
 [564 rows x 1 columns],
 's32A070':                                  32A070
 Field_Collection_Start_Date            
 1959-08-31                    25.500000
 1959-09-30                   254.250000
 1959-10-31                   325.250000
 1959-11-30                   593.666667
 1959-12-31                          NaN
 ...                                 ...
 2019-03-31                   500.000000
 2019-04-30                          NaN
 2019-05-31                          NaN
 2019-06-30                   369.000000
 2019-07-31                    59.000000
 
 [720 rows x 1 columns],
 's34A070':                              34A070
 Field_Collection_Start_Date        
 1959-07-31                     26.0
 1959-08-31                     51.0
 1959-09-30                    120.0
 1959-10-31                      NaN
 1959-11-30                    160.0
 ...                             ...
 2018-05-31                    246.0
 2018-06-30                     62.0
 2018-07-31                     16.0
 2018-08-31                      5.0
 2018-09-30                      4.0
 
 [711 rows x 1 columns],
 's35B060':                              35B060
 Field_Collection_Start_Date        
 1973-10-31                     78.5
 1973-11-30                      NaN
 1973-12-31                    287.5
 1974-01-31                    437.5
 1974-02-28                    407.5
 ...                             ...
 2017-10-31                     90.2
 2017-11-30                    123.0
 2017-12-31                    136.0
 2018-01-31                    229.0
 2018-02-28                    627.0
 
 [533 rows x 1 columns],
 's36A070':                                36A070
 Field_Collection_Start_Date          
 1961-10-31                    69800.0
 1961-11-30                    70800.0
 1961-12-31                    63200.0
 1962-01-31                    77300.0
 1962-02-28                    65900.0
 ...                               ...
 2017-10-31                    95200.0
 2017-11-30                    60000.0
 2017-12-31                   107000.0
 2018-01-31                   104000.0
 2018-02-28                   144000.0
 
 [677 rows x 1 columns],
 's37A090':                               37A090
 Field_Collection_Start_Date         
 1947-06-30                    5000.0
 1947-07-31                       NaN
 1947-08-31                       NaN
 1947-09-30                       NaN
 1947-10-31                       NaN
 ...                              ...
 2018-05-31                   11800.0
 2018-06-30                    2210.0
 2018-07-31                     976.0
 2018-08-31                    1140.0
 2018-09-30                    1880.0
 
 [856 rows x 1 columns],
 's41A070':                                  41A070
 Field_Collection_Start_Date            
 1959-10-31                    79.666667
 1959-11-30                    59.500000
 1959-12-31                    58.500000
 1960-01-31                    50.333333
 1960-02-29                    99.000000
 ...                                 ...
 2017-10-31                   229.000000
 2017-11-30                   169.000000
 2017-12-31                   171.000000
 2018-01-31                   181.000000
 2018-02-28                   191.000000
 
 [701 rows x 1 columns],
 's45A070':                               45A070
 Field_Collection_Start_Date         
 1971-10-31                     771.5
 1971-11-30                    1845.0
 1971-12-31                    1015.0
 1972-01-31                    1910.0
 1972-02-29                    1710.0
 ...                              ...
 2018-05-31                   18200.0
 2018-06-30                    6830.0
 2018-07-31                    2390.0
 2018-08-31                     764.0
 2018-09-30                     460.0
 
 [564 rows x 1 columns],
 's46A070':                              46A070
 Field_Collection_Start_Date        
 1971-10-31                    133.5
 1971-11-30                    131.0
 1971-12-31                    110.0
 1972-01-31                    115.0
 1972-02-29                      NaN
 ...                             ...
 2018-05-31                   4010.0
 2018-06-30                   1150.0
 2018-07-31                    379.0
 2018-08-31                    155.0
 2018-09-30                     99.0
 
 [564 rows x 1 columns],
 's48A140':                               48A140
 Field_Collection_Start_Date         
 1988-10-31                     266.0
 1988-11-30                     360.0
 1988-12-31                     370.0
 1989-01-31                     240.0
 1989-02-28                     266.0
 ...                              ...
 2018-05-31                   16100.0
 2018-06-30                       NaN
 2018-07-31                     880.0
 2018-08-31                     347.0
 2018-09-30                     288.0
 
 [360 rows x 1 columns],
 's49B070':                              49B070
 Field_Collection_Start_Date        
 1961-11-30                    446.0
 1961-12-31                      NaN
 1962-01-31                      NaN
 1962-02-28                   1170.0
 1962-03-31                      NaN
 ...                             ...
 2017-05-31                   6256.0
 2017-06-30                   2734.0
 2017-07-31                    348.0
 2017-08-31                     98.0
 2017-09-30                     73.0
 
 [671 rows x 1 columns],
 's53A070':                                53A070
 Field_Collection_Start_Date          
 1948-12-31                    43200.0
 1949-01-31                        NaN
 1949-02-28                    40000.0
 1949-03-31                        NaN
 1949-04-30                   134700.0
 ...                               ...
 2017-05-31                   169500.0
 2017-06-30                   176300.0
 2017-07-31                   131200.0
 2017-08-31                    90500.0
 2017-09-30                    56900.0
 
 [826 rows x 1 columns],
 's54A120':                               54A120
 Field_Collection_Start_Date         
 1972-10-31                    1940.0
 1972-11-30                    2630.0
 1972-12-31                    4600.0
 1973-01-31                    4660.0
 1973-02-28                    4450.0
 ...                              ...
 2018-05-31                   23900.0
 2018-06-30                    8840.0
 2018-07-31                    2080.0
 2018-08-31                    1150.0
 2018-09-30                    1410.0
 
 [552 rows x 1 columns],
 's56A070':                                  56A070
 Field_Collection_Start_Date            
 1972-10-31                    16.500000
 1972-11-30                    21.000000
 1972-12-31                   112.000000
 1973-01-31                   400.000000
 1973-02-28                   116.666667
 ...                                 ...
 2019-04-30                          NaN
 2019-05-31                          NaN
 2019-06-30                          NaN
 2019-07-31                          NaN
 2019-08-31                    24.000000
 
 [563 rows x 1 columns],
 's57A150':                               57A150
 Field_Collection_Start_Date         
 1959-07-31                     760.0
 1959-08-31                     220.0
 1959-09-30                    1350.0
 1959-10-31                       NaN
 1959-11-30                    5000.0
 ...                              ...
 2017-10-31                    1800.0
 2017-11-30                    2550.0
 2017-12-31                    5020.0
 2018-01-31                    5270.0
 2018-02-28                   16100.0
 
 [704 rows x 1 columns],
 's60A070':                               60A070
 Field_Collection_Start_Date         
 1960-10-31                       0.0
 1960-11-30                       NaN
 1960-12-31                       NaN
 1961-01-31                       NaN
 1961-02-28                       NaN
 ...                              ...
 2018-05-31                   27900.0
 2018-06-30                    9320.0
 2018-07-31                    2260.0
 2018-08-31                     485.0
 2018-09-30                     234.0
 
 [696 rows x 1 columns],
 's61A070':                                61A070
 Field_Collection_Start_Date          
 1951-11-30                    46595.0
 1951-12-31                    40415.0
 1952-01-31                    38830.0
 1952-02-29                    39495.0
 1952-03-31                    38670.0
 ...                               ...
 2018-05-31                   174000.0
 2018-06-30                   241000.0
 2018-07-31                   133000.0
 2018-08-31                   108000.0
 2018-09-30                   616000.0
 
 [803 rows x 1 columns]}
In [32]:
runoff=pd.concat(dict, axis=1)
In [33]:
runoff.columns=list(dict.keys()) #This resets their column name to represent the stations
runoff
#Because of the previous groupby month function, the monthly averages are compared for each station.
#NaNs represent months where certain stations did not have any measurements available. These will not be considered for the correlation.
Out[33]:
s01A120 s03A060 s04A100 s05A070 s07A090 s08C070 s09A190 s10A070 s11A070 s13A060 ... s45A070 s46A070 s48A140 s49B070 s53A070 s54A120 s56A070 s57A150 s60A070 s61A070
Field_Collection_Start_Date
1947-06-30 NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
1947-07-31 NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
1947-08-31 NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
1947-09-30 NaN 6360.0 NaN NaN NaN NaN NaN NaN NaN NaN ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
1947-10-31 NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
2019-05-31 14.0 12300.0 5440.0 NaN 8400.0 374.0 NaN 3000.0 641.0 178.0 ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
2019-06-30 NaN 17400.0 5650.0 NaN 6960.0 338.0 NaN 3180.0 534.0 102.0 ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
2019-07-31 13.0 8510.0 3130.0 NaN 2710.0 NaN NaN 1860.0 540.0 117.0 ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN
2019-08-31 18.0 7430.0 2750.0 NaN 1930.0 338.0 NaN 2050.0 NaN NaN ... NaN NaN NaN NaN NaN NaN 24.0 NaN NaN NaN
2019-09-30 11.0 10500.0 4730.0 NaN 4100.0 206.0 NaN 1630.0 NaN 81.0 ... NaN NaN NaN NaN NaN NaN NaN NaN NaN NaN

868 rows × 34 columns

In [34]:
#Running a seaborn correlation matrix on all runoff data
plt.figure(figsize=(15,15))
sb.heatmap(runoff.corr(), annot=False, fmt=".2f", cmap='Blues', vmin=0, vmax=1, square=True,linewidth=1)
Out[34]:
<Axes: >

The correlation coefficient is a simple statistical measurement that describes the linear relationship between two variables, i.e. the relationship between all runoff measurements at one station with those at another. While it can be used to represent a relationship, correlation alone cannot indicate cause and effect. According to the pandas documentation of DataFrame.corr, the corr function, "compute[s] pairwise correlation of columns, excluding NA/null values." https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.corr.html

The Seaborn correlation matrix plots the correlation of all stations with all other stations using a heatmap. The diagonal line of 1.0 correlation values are to be expected as they represent the correlation of a station with itself. Since stations are numbered in a semi-spatial order, we can recognize higher correlation with "nearby" stations.

The next steps incorporate this information into our WRIA plot to better visualize this spatial correlation.

In [36]:
#Creating a new geopandas dataframe from wria that only includes those watersheds that have runoff data (and thereby, correlation data) available
wria_corr=wria
nrs=[1,3,4,5,7,8,9,10,11,13,16,18,20,22,23,24,26,27,32,34,35,36,37,41,45,46,48,49,53,54,56,57,60,61]
wria_corr=wria_corr[wria_corr['WRIA_NR'].isin(nrs)]
wria_corr=wria_corr.sort_values(by='WRIA_NR')
In [37]:
#This corrwith function calculates correlation for the station 01A120 with all other stations in the dataframe
corr=runoff.corrwith(runoff['s01A120'])
wria_corr['Correlation']=corr.values

#Plotting the correlation as a cloropleth
fig, ax = plt.subplots(figsize=(10, 6)) 
wria.plot(ax=ax, color='lightgrey')
wria_corr.plot(wria_corr['Correlation'], ax=ax, cmap='BuPu', legend=True)
stations[stations['Location_ID']=='01A120'].plot(ax=ax, marker='P', color='lightblue',markersize=80, label='01A120 - Nooksack')
stations[stations['Location_ID']=='03A060'].plot(ax=ax, marker='P', color='green',markersize=80, label='03A060 - Skagit')
stations[stations['Location_ID']=='48A140'].plot(ax=ax, marker='P', color='red',markersize=80, label='48A140 - Methow')
plt.legend()
plt.title('Correlation of Monthly Runoff Values with Station 01A120')
Out[37]:
Text(0.5, 1.0, 'Correlation of Monthly Runoff Values with Station 01A120')
In [38]:
#Let's look at a 10 year time series for runoff at the Nooksack and Skagit rivers, which have a high correlation...
plt.figure(figsize=(12,4))
runoff['s01A120'].loc[((runoff.index >= '1995-01-01') & (runoff.index < '2015-01-01'))].plot(label='01A120 - Nooksack', color='blue')
runoff['s03A060'].loc[((runoff.index >= '1995-01-01') & (runoff.index < '2015-01-01'))].plot(label='03A060 - Skagit', color='green')
#vs. the Methow River, which has a low correlation with the Nooksack
runoff['s48A140'].loc[((runoff.index >= '1995-01-01') & (runoff.index < '2015-01-01'))].plot(label='48A140 - Methow', color='red')
plt.legend()
plt.ylabel('cfs')
plt.title('Runoff')
Out[38]:
Text(0.5, 1.0, 'Runoff')
In [39]:
#Defining the stationcorr function, which produces a cloropleth map of correlation for a given station
def stationcorr(s):
    corr=runoff.corrwith(runoff[s]) #The corrwith function is run on the given station label,
    wria_corr['Correlation']=corr.values #which is used to redefine the 'Correlation' column of the wria geopandas dataframe
    fig, ax = plt.subplots(figsize=(10, 6)) #A plot is set up to plot the Correlation values
    wria.plot(ax=ax, color='lightgrey') #This plots the original wria with all stations underneath the cloropleth. 
    #Those WRIAs without runoff data will be grey.
    wria_corr.plot(wria_corr['Correlation'], ax=ax, cmap='BuPu', legend=True)
    m=s[1:] #This marks the location of the station for correlation
    stations[stations['Location_ID']==m].plot(ax=ax, marker='+', color='white',markersize=80)
    plt.title('Correlation of Monthly Runoff Values with Station '+m)
    return plt

Now, any station name can be entered into the stationcorr() function to create a correlation cloropleth across Washington.

The WRIAs provide a suitable area to visualize the spatial correlation between runoff measurement stations. However, within this project each WRIA is only represented by a single station within it's bounds. Because of the nature of rivers and flow measurements, runoff data and the derived correlation is highly variable and cannot be considered uniform across all WRIAs.

In [41]:
stationcorr('s34A070')
Out[41]:
<module 'matplotlib.pyplot' from 'C:\\Users\\anton\\anaconda3\\Lib\\site-packages\\matplotlib\\pyplot.py'>

Station 41A070 (Crab Creek near Beverly) is notable in that it shows extremely low and the only negative correlation with other stations across the state. This is seen both in the seaborn heatmap as well as in the cloropleths.

The reason for this lack of correlation is not immediately clear. However, when we plot this runoff with the runoff in the Columbia River, which is one of Washington's major rivers and immediately south of station 41A070, we see that the river flow at Lower Crab is neglible to that of the nearby station. Additionally, Crab Creek serves as an irrigation drain into the Columbia River and only flows intermittently from agricultural runoff, not natural water sources. This is a result of the Columbia Basin Project of the last century, during which the Grand Coulee Dam was built to provide hydroelectric power and irrigation water across central Washington. More information can be found here: https://www.usbr.gov/pn/grandcoulee/cbp/index.html

In [43]:
stationcorr('s41A070')
Out[43]:
<module 'matplotlib.pyplot' from 'C:\\Users\\anton\\anaconda3\\Lib\\site-packages\\matplotlib\\pyplot.py'>
In [44]:
plt.figure(figsize=(12,4))
runoff['s41A070'].loc[((runoff.index >= '1995-01-01') & (runoff.index < '2015-01-01'))].plot(label='410A70 - Lower Crab Creek', color='blue')
runoff['s36A070'].loc[((runoff.index >= '1995-01-01') & (runoff.index < '2015-01-01'))].plot(label='360A70 - Alkali Squilchuck', color='red')
plt.legend()
plt.ylabel('cfs')
plt.title('Runoff')
Out[44]:
Text(0.5, 1.0, 'Runoff')
In [45]:
#Running this cell will run the stationcorr function for all stations!
#runoff.columns
#for x in runoff.columns:
 #   stationcorr(x)

Conclusion

Based on this initial analysis of runoff correlation across measurement stations in Washington, we can assume a degree of spatial correlation for river runoff in nearby watersheds.

The initial project proposal also suggested looking at the changes in runoff over time. However, calculation of decadal runoff means for each station, as well as a visual analysis of runoff time series, do not show any noteworthy changes since the 1970's. Further research may consider looking at flooding events or correlation with precipitation to better understand the factors affecting runoff and how these may be changing.

Additionally, the correlation analysis could be further expanded upon by considering certain extremely high or low runoff events, bringing in data from more stations and other variables (i.e. precipitation), and comparing runoff at different stations along the same river.