Open tkknow4 opened 1 year ago
Module 3 - Project: Downloading Weather Data
I'm so excited, eager to accomplish, much more than coding, thank you.
Purpose: Build weather database from NOAA data #Name: Terry Knowles #Date: 05/17/2023
See https://pypi.org/project/noaa-sdk/ for details on noaa_sdk package used
from noaa_sdk import noaa import sqlite3 import datetime
parameters for retrieving NOAA weather data
zipCode = "76116" # change to your postal code country = "US" #date-time format is yyyy-mm-ddThh:mm:ssZ, times are Zulu time (GMT) #gets the most recent 14 days of data today = datetime.datetime.now() past = today - datetime.timedelta(days=14) startDate = past.strftime("%Y-%m-%dT00:00:00Z") endDate = today.strftime("%Y-%m-%dT23:59:59Z")
Purpose: Build weather database from NOAA data
Name: Terry Knowles
Date: 05/17/2023
See https://pypi.org/project/noaa-sdk/ for details on noaa_sdk package used
from noaa_sdk import noaa import sqlite3 import datetime
parameters for retrieving NOAA weather data
zipCode = "76116" # change to your postal code country = "US"
date-time format is yyyy-mm-ddThh:mm:ssZ, times are Zulu time (GMT)
gets the most recent 14 days of data
today = datetime.datetime.now() past = today - datetime.timedelta(days=14) startDate = past.strftime("%Y-%m-%dT00:00:00Z") endDate = today.strftime("%Y-%m-%dT23:59:59Z")