I was learning some Python over the weekend, and then afterwards decided to go for a jog at my favorite spot. As I was jogging, I thought about finding out what the temperature trend at this location was by extracting and plotting it with Python. This site seems to offer the best local 4km data for the continental US.
Well look at that: no warming where I like to jog. How about downtowns of some big cities?
OK. Definitely warming here.
Then I had a great idea. What if I chose spots with coal plants?
Units are degrees Celcius per year, based off the linear regression.
I suspect this fact will not cause climate alarmists to pause and think for one second.
Above, Sammis image turned out to be a duplicate of Roxboro. Corrected.
# Zoe Phin, 2021/05/09
# File: prism.py
# Setup: sudo apt-get install python3-numpy python3-matplotlib
# Run: python3 prism.py
import requests as req
import numpy as np
import matplotlib.pyplot as mp
locations = {
'Roswell':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'34','lon':'-84.385'},
'NYC':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'40.7', 'lon':'-74'},
'LosAngeles':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'34.0543', 'lon':'-118.2438'},
'WashingtonDC':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'38.8968','lon':'-77.0366'},
'Chicago':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'41.8758','lon':'-87.6191'},
'Bowden':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'34.1271','lon':'-84.9155'},
'Scherer':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'33.0667','lon':'-84.8'},
'Gibson':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'38.3697','lon':'-87.7702'},
'Monroe':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'41.8881','lon':'-83.3453'},
'Amos':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'38.4746','lon':'-81.8233'},
'Miller':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'33.6327','lon':'-87.0595'},
'Parish':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'29.4797','lon':'-95.6320'},
'Cumberland':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'36.3906','lon':'-87.6537'},
'Gavin':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'38.9366','lon':'-82.1162'},
'Rockport':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'37.9268','lon':'-87.0354'},
'Paradise':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'37.2585','lon':'-86.9799'},
'Roxboro':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'36.4840','lon':'-79.0725'},
'Sammis':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'40.5686','lon':'-80.4311'},
'Stuart':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'38.6375','lon':'-83.6921'},
'Navajo':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'36.9054','lon':'-111.3877'},
'Sherburne':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'45.3795','lon':'-93.8960'},
'Martin':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'32.2597','lon':'-94.5692'},
'Belews':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'36.2824','lon':'-80.0592'},
'Jeffrey':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'39.2857','lon':'-96.1166'},
'Gaston':{'spares':'4km','call':'pp/yearly_timeseries','proc':'gridserv','units':'si','stats':'tmean','start':'1920','end':'2019','lat':'33.2430','lon':'-86.4595'}}
for name in locations:
res = req.post('https://prism.oregonstate.edu/explorer/dataexplorer/rpc.php',data=locations[name])
y = np.array(res.json()['result']['data']['tmean'])
x = np.arange(1920,2020)
mp.title(name)
mp.plot(x, y)
m, b = np.polyfit(x, y, 1)
print("%-20s %+.4f" % (name, m))
mp.plot(x, m*x+b)
mp.tight_layout()
mp.savefig(name+'.png')
mp.cla()