Mynd:Ohio temps qq.svg

Úr SignWiki
Jump to navigation Jump to search

Upphafleg skrá(SVG-skrá, að nafni til 360 × 315 mynddílar, skráarstærð: 27 KB)

Skrá þessi er af Wikimedia Commons, og deilt meðal annarra verkefna og nýtist því þar. Hér fyrir neðan er afrit af skráarsíðunni þar.

Lýsing

Lýsing
English: A quantile-quantile plot comparing the distributions of daily maximum temperature in the U.S. state of Ohio in March and in July.
Dagsetning
Uppruni eigin skrá
Höfundarréttarhafi Skbkekas
SVG genesis
InfoField
 
The SVG code is valid.
 
This plot was created with Matplotlib.
Source code
InfoField

Python code

## "state33" data file obtained from: ftp://ftp.ncdc.noaa.gov/pub/data/ushcn/daily/README

import gzip
import numpy as np
import matplotlib.pyplot as plt

fid = gzip.open("state33.gz")

month1 = 3
month2 = 7

M1,M2 = [],[]
for line in fid:

    stid = int(line[0:7])

    if line[7:11]=="TMAX":
        mo = int(line[17:19])
        nday = int(line[20:22])
        if mo not in [month1,month2]: continue
        V,ii = [],26
        for k in range(nday):
            V.append(float(line[ii:ii+2]))
            ii += 8
        if mo==month1: M1.extend(V)
        if mo==month2: M2.extend(V)

M1 = np.array(np.sort(M1))
M2 = np.array(np.sort(M2))

M1 = M1[M1!=99]
M2 = M2[M2!=99]

M1 = (M1-M1.mean())/M1.std()
M2 = (M2-M2.mean())/M2.std()

Q1 = [M1[int(q*len(M1))] for q in np.arange(1,1000,dtype=np.float64)/1000]
Q2 = [M2[int(q*len(M2))] for q in np.arange(1,1000,dtype=np.float64)/1000]

P1 = [M1[int(q*len(M1))] for q in np.arange(1,10,dtype=np.float64)/10]
P2 = [M2[int(q*len(M2))] for q in np.arange(1,10,dtype=np.float64)/10]

plt.clf()
plt.figure(figsize=(4,3.5))
plt.axes([0.15,0.15,0.8,0.8])
plt.grid(True)
plt.plot(Q1, Q2, '-', color="gray", lw=3)
plt.hold(True)
plt.plot([-3,3], [-3,3], '-', color='black')
plt.plot(P1, P2, 'o', mec='black', mfc='red')
plt.xlim(-2,3)
plt.ylim(-2,3)
plt.xlabel("March", size=14)
plt.ylabel("July", size=14)
plt.savefig("ohio_temps_qq.pdf")
plt.savefig("ohio_temps_qq.svg")

Leyfisupplýsingar:

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
tilvísun höfundarréttar
This file is licensed under the Creative Commons Attribution 3.0 Unported license.
Þér er frjálst:
  • að deila – að afrita, deila og yfirfæra verkið
  • að blanda – að breyta verkinu
Undir eftirfarandi skilmálum:
  • tilvísun höfundarréttar – Þú verður að tilgreina viðurkenningu á höfundarréttindum, gefa upp tengil á notkunarleyfið og gefa til kynna ef breytingar hafa verið gerðar. Þú getur gert þetta á einhvern ásættanlegan máta, en ekki á nokkurn þann hátt sem bendi til þess að leyfisveitandinn styðji þig eða notkun þína á verkinu.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts enska

13. nóvember 2009

Breytingaskrá skjals

Smelltu á dagsetningu eða tímasetningu til að sjá hvernig hún leit þá út.

Dagsetning/TímiSmámyndVíddirNotandiAthugasemd
núverandi13. nóvember 2009 kl. 14:52Smámynd útgáfunnar frá 13. nóvember 2009, kl. 14:52360 × 315 (27 KB)Skbkekas{{Information |Description={{en|1=A quantile-quantile plot comparing the distributions of daily maximum temperature in the U.S. state of Ohio in March and in July.}} |Source={{own}} |Author=Skbkekas |Date=2009-11-13 |Permission= |other_v

Eftirfarandi síða notar þessa skrá: