nws-flood-thresholds

Download flood stage thresholds from NWS (National Weather Service). Use when determining flood levels for USGS stations, accessing action/minor/moderate/major flood stages, or matching stations to their flood thresholds.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "nws-flood-thresholds" with this command: npx skills add wu-uk/flood-risk-analysis-nws-flood-thresholds

NWS Flood Thresholds Guide

Overview

The National Weather Service (NWS) maintains flood stage thresholds for thousands of stream gages across the United States. These thresholds define when water levels become hazardous.

Data Sources

Option 1: Bulk CSV Download (Recommended for Multiple Stations)

https://water.noaa.gov/resources/downloads/reports/nwps_all_gauges_report.csv

Option 2: Individual Station Pages

https://water.noaa.gov/gauges/<station_id>

Example: https://water.noaa.gov/gauges/04118105

Flood Stage Categories

CategoryCSV ColumnDescription
Action Stageaction stageWater level requiring monitoring, preparation may be needed
Flood Stage (Minor)flood stageMinimal property damage, some public threat. Use this to determine if flooding occurred.
Moderate Flood Stagemoderate flood stageStructure inundation, evacuations may be needed
Major Flood Stagemajor flood stageExtensive damage, significant evacuations required

For general flood detection, use the flood stage column as the threshold.

Downloading Bulk CSV

import pandas as pd
import csv
import urllib.request
import io

nws_url = "https://water.noaa.gov/resources/downloads/reports/nwps_all_gauges_report.csv"

response = urllib.request.urlopen(nws_url)
content = response.read().decode('utf-8')
reader = csv.reader(io.StringIO(content))
headers = next(reader)
data = [row[:43] for row in reader]  # Truncate to 43 columns
nws_df = pd.DataFrame(data, columns=headers)

Important: CSV Column Mismatch

The NWS CSV has a known issue: header row has 43 columns but data rows have 44 columns. Always truncate data rows to match header count:

data = [row[:43] for row in reader]

Key Columns

Column NameDescription
usgs idUSGS station ID (8-digit string)
location nameStation name/location
stateTwo-letter state code
action stageAction threshold (feet)
flood stageMinor flood threshold (feet)
moderate flood stageModerate flood threshold (feet)
major flood stageMajor flood threshold (feet)

Converting to Numeric

Threshold columns need conversion from strings:

nws_df['flood stage'] = pd.to_numeric(nws_df['flood stage'], errors='coerce')

Filtering by State

# Get stations for a specific state
state_stations = nws_df[
    (nws_df['state'] == '<STATE_CODE>') &
    (nws_df['usgs id'].notna()) &
    (nws_df['usgs id'] != '') &
    (nws_df['flood stage'].notna()) &
    (nws_df['flood stage'] != -9999)
]

Matching Thresholds to Station IDs

# Build a dictionary of station thresholds
station_ids = ['<id_1>', '<id_2>', '<id_3>']
thresholds = {}

for _, row in nws_df.iterrows():
    usgs_id = str(row['usgs id']).strip()
    if usgs_id in station_ids:
        thresholds[usgs_id] = {
            'name': row['location name'],
            'flood': row['flood stage']
        }

Common Issues

IssueCauseSolution
Column mismatch errorCSV has 44 data columns but 43 headersTruncate rows to 43 columns
Missing thresholdsStation not in NWS databaseSkip station or use alternative source
Value is -9999No threshold definedFilter out these values
Empty usgs idNWS-only stationFilter by usgs id != ''

Best Practices

  • Always truncate CSV rows to match header count
  • Convert threshold columns to numeric before comparison
  • Filter out -9999 values (indicates no threshold defined)
  • Match stations by USGS ID (8-digit string with leading zeros)
  • Some stations may have flood stage but not action/moderate/major

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

General

Multi Edge-TTS CN

Edge-TTS 在线语音合成 skill。基于微软 Edge TTS 引擎,生成速度快(1-2秒),支持多种音色和输出格式。同时支持飞书(OGG/Opus)和企业微信(AMR)。默认音色 xiaoxiao_lively。需联网。

Registry SourceRecently Updated
General

vedic-destiny

吠陀命盘分析中文入口。用于完整命盘研判、命主盘 Rashi chart 与九分盘 Navamsha chart 联读、既往事件回看、出生时间稳定度判断、事业主题、婚姻主题、时空盘专题,以及基于 Jagannatha Hora PDF、星盘截图或文本命盘数据的系统拆盘。当用户提到完整星盘、事业方向、婚姻问题、关系窗...

Registry SourceRecently Updated
General

One Person Company OS

Build a visual operating cockpit for an AI-native one-person company across promise, buyer, product, delivery, cash, learning, and assets. / 为 AI 一人公司建立可视化经营...

Registry SourceRecently Updated
General

健康追踪

健康追踪技能 - 追踪饮水、睡眠、步数等健康数据,JSON存储。

Registry SourceRecently Updated