You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

485 lines
323 KiB
Plaintext

{
"metadata": {
"name": "WAFO Chapter 5"
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Chapter 5 Extreme value analysis\n",
"=================================\n",
"Section 5.1 Weibull and Gumbel papers\n",
"--------------------------------------\n",
"Significant wave-height data on Weibull paper,\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"clf()\n",
"import wafo.data as wd\n",
"import wafo.stats as ws\n",
"import matplotlib.pyplot as plt\n",
"Hs = wd.atlantic()\n",
"wei = ws.weibull_min.fit2(Hs)\n",
"tmp = ws.probplot(Hs, wei.par, dist='weibull_min', plot=plt)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAX4AAAEWCAYAAABhffzLAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlcVPX+x/HXDDuIiooogst1ZRfRa1oipqiVqKGmqEmo\nWVmW1S+9uSTaNdu71tUWr5lpLpm54r4gllopimsuKAnuiuygMJzfH0cGUAzQYQaYz/Px8CGcOTPn\nM5RvvvM53/M9GkVRFIQQQpgNrakLEEIIYVwS/EIIYWYk+IUQwsxI8AshhJmR4BdCCDMjwS+EEGZG\ngl9UC1qtlrNnzz7Qc5s2bcr27dtLfGz37t20adOm2L47duwA4L333uP5559/oGOWR3R0NO7u7hV+\nHGE+JPiFyTRt2hR7e3scHR1p0KABERERZGZmGr0OjUaDRqMp8bEuXbrw559/Ftu3wKRJk5g3bx4A\nCQkJaLVa8vPzH6iG7777DgsLCxwdHalVqxb+/v5ERUWV+3Wee+45pk6d+kA1CPMhwS9MRqPRsH79\netLT04mNjWX//v38+9//vme/vLw8E1T3YB7meshHH32U9PR0UlJSGDVqFM888wwpKSkGrE4IlQS/\nqBRcX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d4GM9B/J5uGbaVyrsanL\nMgqT9Pi//fZbwsLCSnwsMjJS/3VQUBBBQUHGKUoIYTZO3zhNxJoILLWW/Db6N/7h9A9Tl1Qu0dHR\nREdHP/DzK2wef0JCAiEhIRw5cqTY9pkzZxIbG8vKlSvvLUbm8QshKlC+ks+c3+cwfdd0pgZOZVzH\ncWg1VX8Bg0o9j/+7775jw4YN
}
],
"prompt_number": 3
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Significant wave-height data on Gumbel paper,"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"gum = ws.gumbel_r.fit2(Hs)\n",
"tmp = ws.probplot(Hs, gum.par, dist='gumbel_r', plot=plt)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stderr",
"text": [
"c:\\pab\\workspace\\pywafo_svn\\pywafo\\src\\wafo\\stats\\estimation.py:722: RuntimeWarning: invalid value encountered in sqrt\n",
" self.par_lower = self.par - zcrit * sqrt(pvar)\n",
"c:\\pab\\workspace\\pywafo_svn\\pywafo\\src\\wafo\\stats\\estimation.py:723: RuntimeWarning: invalid value encountered in sqrt\n",
" self.par_upper = self.par + zcrit * sqrt(pvar)\n"
]
},
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAX4AAAEWCAYAAABhffzLAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlYVHX7x/H3sMkiIiLigqLhhmwqmraI5F6JC5qFmrvZ\n8rT6pE9aT2S5lPkz9ckW03LPMldQMxfESlNBCZdEERLcNxbZGc7vjyMDCIToMAPM/bquLpkz58y5\n8coPX+7zPd+jURRFQQghhMkwM3YBQgghDEuCXwghTIwEvxBCmBgJfiGEMDES/EIIYWIk+IUQwsRI\n8IsawczMjHPnzt3Xsc2bN2f37t2lvrd//37atm1bbN89e/YAMGvWLCZOnHhf56yI8PBwmjZtWunn\nEaZDgl8YTfPmzbG1tcXe3p6GDRsydu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xsStE1kxeAVze8+V0C+iUlo990taPUKIB3X0\n0lFGbBiBb0NfFj+1GEebkrMMa5oq1+oRQghD0OZr+fT3T5l3YB6f9fuM4d7DjV1SlSXBL4So9v5O\n/ptRm0ahQcPhiYdxqys3iv6T6jufSQhh8hRFYdWfq+i8pDNPt3qa3aN2S+jfAxnxCyGqpVuZt3gp\n7CVirsaw8/mdtG/Y3tglVRsy4hdCVDt74vfg+6UvLrVdODLxiIR+BcmIXwhRbWTnZTN9z3S+P/49\nywYuo497H2OXVC1J8AshqoWYKzGM2DCCVk6tiH4xGidbJ2OXVG1J8AshqrR8JZ/PDn7G7F9nM7f3\nXEb7jjbojaBhYREsXLiT7GwL
}
],
"prompt_number": 4
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Significant wave-height data on Normal probability paper,\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"tmp = ws.probplot(np.log(Hs), plot=plt)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAX8AAAEWCAYAAACOv5f1AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlcVPX+x/HXsO+IgpCIS4jKDmphi4qaUipqZilqmtLN\nW1etbvdmiSZW2m27/bTStD3Npby5omapiLlkAuaCuRDE4r6A7Mtwfn8cGUFAUAcGmM/z8eCRc+bM\nzAe89+2Xz/l+v0ejKIqCEEIIo2Ji6AKEEEI0PAl/IYQwQhL+QghhhCT8hRDCCEn4CyGEEZLwF0II\nIyThL5odExMT/vzzz9t6bYcOHdi2bVu1z+3atYuuXbtWOnf79u0AzJs3j7/97W+39Zm3IjY2Fg8P\nj3r/HNH8SfiLRqFDhw7Y2Nhgb2+Pm5sbEydOJC8vr8Hr0Gg0aDSaap/r1asXf/zxR6Vzy82YMYNP\nP/0UgNTUVExMTCgrK7utGr766itMTU2xt7fH0dGR4OBgYmJibvl9nnrqKWbNmnVb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Z9oSmt4TXWB\nbmlZ/dlWVlo9Vtuw9D7yd3NzIygoCAA7Ozu8vb05ffp0lfOkly+EqG+5Lqfg2QAwKYWFh+HPAYAa\n2rcS6NOmDcTTM6rSMU/PGUydOkD/RTeQeu35p6amkpiYSEhISKXjGo2GPXv2EBgYiLu7O++99x4+\nPj71WYoQwojkFufyys+vkBq8FbctfTm763Pdc2poPwyoPf7KF3GvP1dReV//ww9nUVhoipWVlqlT\nH26y/X6ox/DPzc1l5MiRzJ8/
}
],
"prompt_number": 5
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Return values in the Gumbel distribution"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"clf()\n",
"T=np.r_[1:100001]\n",
"#sT=gum.par[1] - gum.par[0]*log(-log(1-1./T));\n",
"sT = gum.isf(1./T)\n",
"semilogx(T,sT), hold\n",
"N=np.r_[1:len(Hs)+1]; \n",
"Nmax=max(N);\n",
"plot(Nmax/N,sort(Hs)[::-1],'.')\n",
"title('Return values in the Gumbel model')\n",
"xlabel('Return period')\n",
"ylabel('Return value') \n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "pyout",
"prompt_number": 6,
"text": [
"<matplotlib.text.Text at 0x6d23570>"
]
},
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYIAAAEeCAYAAACHXhKxAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlYVdX+x/H3ETRBUFAUBxJQM2cxp7JUytTMItMwtZwq\nzcrK2zWt/HXFbrcy61aaDZZTg6VZzmmWiUOmljmVpjmbiiMIqKjA+v2xrwdQkPEMcD6v5+GRs8/e\ne33P8rC/e6+191o2Y4xBREQ8VilXByAiIq6lRCAi4uGUCEREPJwSgYiIh1MiEBHxcEoEIiIeTolA\nnComJoa+ffs6tcxGjRqxcuXKItlXbGws1157bZHsyxUiIyOZPHmy07ctjPzUuSu+XyWBEoGbCAsL\nw9fXF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MoKIht27Zx88032/ed3f3gOS3LSZkyZeje\nvTvLli2jT58+9uV33HEHd9xxB3Xr1iUsLAwfH58sl/aZy6lQoQLvvfcejzzyCCEhIfj5+WVpEnj6\n6aeJioqiU6dOlC9fnptuuon169cD1hVOdHQ0FSpUoEGDBkRGRubpQaL8fs6YmBj69+9PYGAgs2fP\nzvVe+rFjx1KnTh1uvPFGKlSoQMeOHdm5c2e261aqVIm1a9dStmxZbrnlFsqXL0+zZs04c+YM77//\nfp7qKC+fJ/Nrm81Gv379GDBgANWqVePChQv2Gwxy+55dra7yG8cXX3zBvn37qF69Ot27d+ell17i\ntttuA2D06NGEhoYSHh7OHXfc
}
],
"prompt_number": 6
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Section 5.2 Generalized Pareto and Extreme Value distributions\n",
"----------------------------------------------------------\n",
"Section 5.2.1 Generalized Extreme Value distribution\n",
"-------------------------------------------------\n",
"\n",
"Empirical distribution of significant wave-height with estimated Generalized Extreme Value distribution"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"gev = ws.genextreme.fit2(Hs)\n",
"gev.plotesf()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYoAAAETCAYAAAAoF0GbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X18zfX/x/HHmW1KxkbMxbCFuTZiFMNUiKKSuSzX+qav\nRCnfviXzLaRUqu+3+ikXUZZ8uxiyWb5Zrr4oRr6GhU0z1xdTM9mFz++PTztMnF04Z+ec7Xm/3c5t\nfc7nc87ndXbLee39el9ZDMMwEBERuQ4PZwcgIiKuTYlCRERsUqIQERGblChERMQmJQoREbFJiUJE\nRGxSopAyzcfHh5SUlOueHzt2LK+88soN3SM+Pp46derc0HvcKFeIQdyXEoW4nMDAQCpUqICPj4/1\nMX78eIfc67fffiMwMPC6599//31efPFFh9w7T3R0NK1ataJy5cpUq1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SsrlFsNB6vNX3qMFu/Akh900423Gcy7xMFWraiKfiLtRH4XY3fvv\nwxNPXD725xiTmM1I5vMxw5jOC7yx8FaGDXNejCJSdCo9id2MHWuWpfL6MI5Tg2eZTVMS8SaLvTTm\n5+GvcIvlvGZ9i5RiShRSoI4dzYSRt5vocWowjn9xB5tpzv/4mYY8zvv07pmNxQIWC2zc6NyYRcR+\nVHqSIrnW0Nrb2cZrPEcNjjGBOayhG2C2RDp2dEKQImJTmSs9qTO7ZN1779WjpGA7bbiHNfydGXzA\n43zNA9RnP2Fh8MYbzo1XRC5T
}
],
"prompt_number": 7
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import wafo.kdetools as wk\n",
"wk.TKDE(Hs, L2=0.5)(output='plot').plot('g--')\n",
"plt.hold(True)\n",
"gev.plotepdf() "
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYoAAAETCAYAAAAoF0GbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3X18zfX/x/HH2ZUNwzDDzhiGzdVMY7nKKhflyxIqFJJK\nupSUfL8Vvl0Kfb+VLtSXRIpvX/1MYiGGxoxGZGSx2QVzuTXbsJ3t/fvjo1Ozi7PZOedztr3ut9tu\ndnY+n/d5Tjmv83lffQxKKYUQQghRBie9AwghhHBsUiiEEEKUSwqFEEKIckmhEEIIUS4pFEIIIcol\nhUIIIUS5pFAIUUU7d+4kMDDQLq81Z84cxo8fb5fXEuIPUihEjeHv70/dunVp0KABXl5e9O3bl8WL\nF2PrpUL9+/fn6NGjxXJs3brVJq9lMBgqfKwtc4jaRQqFqDEMBgPr168nOzublJQUXnzxRebNm8fk\nyZPtnsNWxaky7doyh6hdpFCIGsnT05Phw4ezevVqPv/8cw4fPgzA1atXmTFjBq1bt6Z58+ZMnTqV\nK1euABAdHY3RaOSdd97Bx8eHli1bsmzZMnObGzZsoHPnzjRo0AC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cyz1HY4/G9PXry4jAEXi4emgHGAzwySfQvTuMHQsdOtj5FxBC6MlmXU/2IF1PFbRqFXz4\nIezYUerTK35ewemc0xgbGDmTc4ao41EcyDjA9ge3E9g08M8D334bdu6Eb7+1U3AhhC1U9r1TCkVN\npxSEhmrTXK/r+ivP4bOHCWwa
}
],
"prompt_number": 8
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Analysis of yura87 wave data. \n",
" Wave data interpolated (spline) and organized in 5-minute intervals\n",
"Normalized to mean 0 and std = 1 to get stationary conditions. \n",
"maximum level over each 5-minute interval analysed by GEV"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import scipy.interpolate as si\n",
"xn = wd.yura87()\n",
"XI = np.r_[0:len(xn):0.25]\n",
"N = len(XI); \n",
"N = N-np.mod(N,4*60*5); \n",
"YI = si.UnivariateSpline(xn[:,0].ravel(),xn[:,1].ravel(),k=3,s=0)(XI[:N])\n",
"YI = np.reshape(YI, (4*60*5, N/(4*60*5))); # Each column holds 5 minutes of interpolated data.\n",
"Y5 = (YI-YI.mean(axis=0))/(YI.std(axis=0))\n",
"Y5M = Y5.max(axis=0)\n",
"Y5gev = ws.genextreme.fit2(Y5M,method='mps')\n",
"Y5gev.plotesf()\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYwAAAETCAYAAAAlCTHcAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlcVPX+x/HXKEvuoCEqKHjdFVRyS9PESktLc0lDTU1x\n7Wplu5WJld72zVZL7WaJact1SYhccKGUUkoTlTJRXHLHXUE4vz9OzE8UZVhmg/fz8ZiHzJwz53zm\nG82H724xDMNAREQkH2WcHYCIiLgHJQwREbGJEoaIiNhECUNERGyihCEiIjZRwhAREZsoYUipVqlS\nJVJTU696fNy4cbz44otFukd8fDy1a9cu0jWKyhViEPenhCEuJzg4mPLly1OpUiXr48EHH7TLvU6d\nOkVwcPBVj3/wwQc8++yzdrl3jkWLFtGyZUuqVKmCn58ft956qzWJRUVF4enpmassXnvtNbvGc//9\n9zN58mS73kPck4ezAxC5nMViYenSpdxyyy1OjSM7O5syZez7N9Wff/7JsGHD+Pbbb+nSpQunT58m\nLi6OsmXLAmZZDBw4kM8++8yucYjYQjUMcSuffvopN910E4888gi+vr7Ur1+fH3/8kTlz5lCnTh38\n/f1zfbnef//9jB07lm7dulG5cmXCw8PZs2eP9XiZMmX466+/rOeOGzeOHj16ULFiRVatWnXFX9uX\n1gbq16/P999/D8CcOXNo2rQplStXpl69esycOdOmz/Prr79St25dunTpAkDFihXp27evtfnIMAxs\nXYwhODiYl156iWbNmlG1alVGjBjBhQsX8jx327ZthIeH4+vrS0hICEuWLAFg5syZzJs3j1deeYVK\nlSpx991323RvKR2UMMQlXetLMjExkRYtWnDs2DEGDhzIgAED2LRpEzt37uTzzz9n/PjxnD171nr+\nvHnzeO655zhy5AgtW7Zk8ODBV712dHQ0kydP5vTp03Ts2BGLxYLFYrHed9iwYbz++uucOHGCNWvW\nWJuz/P39+e677zh58iRz5sxh4sSJJCUl5fs5W7Vqxfbt23nkkUeIj4/n9OnTNpZQ3ubNm0dcXBw7\nd+4kJSUlz/6XzMxMevbsyR133MHhw4eZMWMGgwcPJiUlhdGjRzN48GCefPJJTp06xaJFi4oUj5Qs\nShjicgzDoHfv3vj6+lofs2bNsh6vW7cuw4YNw2KxMGDAAPbv389zzz2Hp6cnXbt2xcvLiz///NN6\n/l133UXHjh3x8vJi2rRp/PTTT+zbty/Pe/fu3Zv27dsD4O3tnevYrFmziIyM5NZbbwWgVq1aNGrU\nCIAePXpQt25dAG6++Wa6devG2rVr8/2sdevWJT4+nn379jFgwAD8/PwYPnw4Z86csZ6zYMECazlU\nrVqVv//+O89rWSwWxo8fT0BAAL6+vjzzzDNER0dfcd769es5c+YMTz31FB4eHnTp0oW77rrLem5B\najVSuihhiMuxWCwsWrSI48ePWx+RkZHW4/7+/tafy5UrB4Cfn1+u13L+UrdYLAQGBlqPVahQgapV\nq7J///4873utkUR79+6lXr16eR6LiYnhxhtvpFq1avj6+rJs2TKOHj1q0+dt164dX375JYcOHWLt\n2rWsWbOGadOmWY/fe++91nI4duwYNWrUuOq1Lo2/Tp06eX7O/fv3X/E5g4KCrOfm1KhELqeEISWa\nYRikpaVZn58+fZpjx45Rq1atAl+rdu3auWouOS5cuEC/fv144oknOHToEMePH6dHjx6F+iu9devW\n9OnTh61bt+b6DLa6tH9mz549eX7OWrVqkZaWluu6u3fvJiAgAFDCkKtTwhCXVJxNIsuWLSMhIYGM\njAwmT55M+/btrV+O+d3z0uaZyMhI5syZw8qVK8nOzmbfvn3s2LGDjIwMMjIyuP766ylTpgwxMTHE\nxcXZFFtCQgKffPIJhw8fBmD79u0sWbKEG2+8scCf0zAM3n//ffbt28exY8eYNm0aERERV5zXrl07\nypcvzyuvvEJmZibx8fEsXbrUeq6/v791IIDIpZQwxCX17Nkz19yDfv36AeTqhM5xrb+ILRYLgwYN\nYurUqVSrVo2kpCQ+//zzPN97tWvnvNamTRtrh7aPj491xFWlSpV45513GDBgAFWrViU6OvqK0UVX\ni9HHx4fFixcTGhpKpUqV6N69O3379uWJJ564akz5fdZu3bpRr149GjRokGsOSc51vLy8WLJkCTEx\nMfj5+TF+/Hjmzp1Lw4YNATMxJicn4+vrS9++fW26t5QOFlfdQOnMmTM88MADeHt7Ex4ezqBBg5wd\nkrih4cOHExgYyAsvvODsUOyubt26zJo1y+nzV6TkctkaxjfffMOAAQOYOXMmixcvdnY44qZc9O8h\nEbfk0IQxYsQI/P39CQ0NzfV6bGwsjRs3pkGDBrz88ssA7Nu3zzqSI2fWq0hBFaRJR0SuzaFNUmvX\nrqVixYoMHTqULVu2AJCVlUWjRo1Yvnw5AQEBtGnThujoaDZu3Iivry933nknAwcOzHM8uYiIOI5D\naxidOnXC19c312uJiYnUr1+f4OBgPD09iYiIYNGiRfTt25evv/6aBx54gF69ejkyTB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HmN/teZs\n3KjEIVKSFfa70+kzvYsqKiqqaOOKS7igIDh0CMLDzdFVnTqZ/wLsoDEP8zb12EkyTYnlDr44ejuR\nwcvx9THYvdupoYtIMYuPjycqKqrQ71cNoxTasgXatoWbb4aVK+HiRfN1Ly4wiHk8xmtcwJsXmMxa\n37vZmFRGNQ6REkRNUlIoOcmjdWtzjgeAhWzuYilTmIoHF3mByXxDXzw8y7BxI1y2nYmIuBklDCmy\nhARzeZL/Z3An3zGFqVzHeV5gMl9xD1jKsHYtWopExE0pYUixyJkUmJVlrm+VkQFg0J0YpjCVCpzh\nGaaxmF74+FioUAGCg80RWfPm
}
],
"prompt_number": 9
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Section 5.2.2 Generalized Pareto distribution\n",
"-------------------------------------------\n",
"Exceedances of significant wave-height data over level 3."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"gpd3 = ws.genpareto.fit2(Hs[Hs>3],floc=3)\n",
"gpd3.plotesf()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYoAAAETCAYAAAAoF0GbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlcVGX7+PHPKKCiKKiICgjkhguKCm7pE2ouWbgvSG64\nVT7aL30s/VYqlva4tmilWbinmZWhpmSauC/5gGnuG4goaiIIorJ4fn+cGEXZmeHMDNf79ZrXAzNn\nzlzH77e5uO/rvq+jUxRFQQghhMhBKa0DEEIIYdokUQghhMiVJAohhBC5kkQhhBAiV5IohBBC5EoS\nhRBCiFxJohAlmp2dHVFRUTm+/sYbbzBz5swifUZ4eDiurq5FOkdRmUIMwnxJohAmx93dHVtbW+zs\n7PSPN9980yiflZSUhLu7e46vL168mPfff98on50pNDQUb29vKlWqhKOjI506ddInr+DgYKytrbP8\nW8yfP9+o8QwfPpypU6ca9TOEebHSOgAhnqbT6diyZQsdO3bUNI5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AsCnvMW3vMpDyuqP\nq1gRjh+X3d5CiKxK3NSTpRSzC8LeHg7/WZYJx0fQvPRxJvAJffiJaNwIZjpVuQU8HmG0aSOb94QQ\nUswu0aKjoXlzcIxX2573ZwPrGMTHTOQStfXHyeY9IQSUwBGFUKeWbt+GDcc9GWf1FQ04zR0cOERr\n1jOAFhwFoH9/WLlS42CFEGZHRhQWaP9+9YZJFUhiJCFM4BMuUpu5vMOvdKVJEx27d8tyWiFKKmnh\nIfROnFB3cluRxgC+5x3mokNh
}
],
"prompt_number": 10
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Exceedances of significant wave-height data over level 7,"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"gpd7 = ws.genpareto.fit2(Hs[Hs>7],floc=7)\n",
"gpd7.plotesf()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYoAAAETCAYAAAAoF0GbAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlclXX6//HXUcEVBZVQQcVUJIXUAk2TxBS3ArdBcQ81\nS39q02I638bEykpbprSmxsml3DMt1ATJFPfcnUwzzUQRNTdIERXF+/fHPTKScNgOHJb38/E4D+Gc\n+9z3dTPTuc7nc30Wi2EYBiIiIlkoY+8ARESkaFOiEBERq5QoRETEKiUKERGxSolCRESsUqIQERGr\nlCikVHNyciIuLi7L10eNGsUbb7yRr2vExsZSt27dfJ0jv4pCDFJ8KVFIkePp6UmlSpVwcnJKf4wb\nN65ArnXlyhU8PT2zfP2TTz7h73//e4Fc+47IyEhatGhBtWrVcHV1pWPHjunJKyIiAgcHhwx/i3ff\nfbdA43nqqaeYNGlSgV5Dipdy9g5A5M8sFgurV6/m8ccft2sct2/fpkyZgv0u9euvvzJ06FC+/vpr\nOnToQHJyMjExMZQtWxYw/xb9+/fniy++KNA4RKxRi0KKlXnz5vHoo4/ywgsv4OLiQqNGjd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gVS520eGYmD4M9\ne7js04a4yk356v6XufLtRrh50563ISKSgVoUBezOhD+LxWxlrFtnPt+yJaxfD87O0KH9bZI37eFJ\nVjPYeTX3W45Dly7MPvsEkand2HeyBvXrm0ln0SLzPSIieVXqahTFKfy7k8bcuf/7wL8z6c/f32yF\nOKechjVr2DJxFQ9e3MB/aM4q
}
],
"prompt_number": 11
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Simulates 100 values from the GEV distribution with parameters (0.3, 1, 2), then estimates the\n",
"parameters using two different methods and plots the estimated distribution functions together\n",
"with the empirical distribution.\n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"Rgev = ws.genextreme.rvs(0.3,1,2,size=100)\n",
"gp = ws.genextreme.fit2(Rgev,method='mps');\n",
"gm = ws.genextreme.fit2(Rgev,method='ml');\n",
"\n",
"gp.plotesf()\n",
"plt.hold(True)\n",
"gm.plotesf('r--')"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYcAAAETCAYAAADd6corAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlcVPX+x/HXIEsiKGi4AYKJilti7qaJmUve9Jam4pZ7\naVcru7f9mljX1luWdqvrzaWstF+rS4o7pVaiRqXikguKoLmgKLiwnd8fJ0YQFJCBmYH38/GYh8yZ\nM3M+M/WYz3y3z9diGIaBiIhILi72DkBERByPkoOIiOSj5CAiIvkoOYiISD5KDiIiko+Sg4iI5KPk\nIBWat7c38fHx13x84sSJ/Otf/yrRNaKjowkMDCzRa5SUI8QgzkXJQRxOcHAwnp6eeHt7W2+PPPJI\nqVzr/PnzBAcHX/Px9957j3/+85+lcu0cS5YsISwsjGrVquHn50f37t2tCSsyMhI3N7c8n8W///3v\nUo1n1KhRTJ06tVSvIY7P1d4BiFzNYrGwfPly7rzzTrvGkZ2djYtL6f5+2r9/PyNHjuTrr7+mW7du\npKamsnr1aipVqgSYn8WQIUP46KOPSjUOkaup5SBOZcGCBdx+++08/vjj+Pr6EhISwg8//MD8+fOp\nV68etWrVyvNFOmrUKCZMmEDPnj2pWrUq4eHhHDlyxPq4i4sLBw8etJ47ceJE+vTpg5eXFxs2bMj3\nKzr3r/yQkBBWrVoFwPz582natClVq1alQYMGzJkzp0jv55dffqF+/fp069YNAC8vL/r372/tAjIM\ng6IWMQgODuaVV16hWbNmVK9enTFjxnD58uUCz929ezfh4eH4+vrSvHlzli1bBsCcOXP49NNPee21\n1/D29uavf/1rka4t5Y+Sgzik630hxsTE0LJlS5KTkxkyZAiDBg3i559/5sCBA3z88cdMmjSJCxcu\nWM//9NNPef755zl16hRhYWEMGzbsmq+9aNEipk6dSmpqKp07d8ZisWCxWKzXHTlyJG+88QYpKSl8\n//331i6pWrVq8e2333Lu3Dnmz5/PlClTiI2NLfR9tm7dmj179vD4448THR1NampqET+hgn366aes\nXr2aAwcOsG/fvgLHSzIyMujbty+9e/fm5MmTzJ49m2HDhrFv3z4efPBBhg0bxlNPPcX58+dZsmRJ\nieIR56XkIA7HMAzuvfdefH19rbe5c+daH69fvz4jR47EYrEwaNAgkpKSeP7553Fzc6NHjx64u7uz\nf/9+6/n33HMPnTt3xt3dnRkzZvDjjz+SmJhY4LXvvfdeOnbsCICHh0eex+bOncvYsWPp3r07AHXr\n1qVx48YA9OnTh/r16wNwxx130LNnTzZu3Fjoe61fvz7R0dEkJiYyaNAg/Pz8GD16NGlpadZz/u//\n/s/6OVSvXp3jx48X+FoWi4VJkybh7++Pr68vzz33HIsWLcp33k8//URaWhpPP/00rq6udOvWjXvu\nucd6bnFaK1J+KTmIw7FYLCxZsoQzZ85Yb2PHjrU+XqtWLevflStXBsDPzy/PsZxf4BaLhYCAAOtj\nVapUoXr16iQlJRV43evN6Dl69CgNGjQo8LGVK1fSoUMHatSoga+vLytWrOD06dNFer/t27fns88+\n48SJE2zcuJHvv/+eGTNmWB8fPHiw9XNITk6mdu3a13yt3PHXq1evw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/N3R1+/50RM0JZezSUP4ya+PhaiI3VOIdIcVSI5DBt2jTrmIM4\nntyJI/eYydVJA3LNMgvMNgdm9u7Ne9uxA06d4tes5gRgDtzspDkf8gALLGPw8VGiELmenDGH6dOn\nl//k4MThV2i5u6U+//w6g+1XS0sjKCCLI2e9qckJmrOTVLyIwRwcdyUdV7Lx877Ilv/9Rp2qF6BN\nGzMbiQhQQVoOThy+3KCcxPLH
}
],
"prompt_number": 17
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Similarly for the GPD distribution"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"Rgpd = ws.genpareto.rvs(0.4,size=100);\n",
"gmps = ws.genpareto.fit2(Rgpd, method='mps')\n",
"gml = ws.genpareto.fit2(Rgpd, method='ml')\n",
"gmps.plotesf()\n",
"plt.hold(True)\n",
"gml.plotesf('r--')"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYsAAAETCAYAAADH1SqlAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlY1WX+PvD7IGguKIsIsgiEC4IIGKipKGpqIWBqKVhq\nqM1UPzNrNG2+lViZaTWVNM1MhVpaak0LgkJuoeRGBo6OeyKI4AYuLCogPL8/njkHSPSwnMPncw73\n67rOJWfhfG5QefPsGiGEABER0T1YKB2AiIjUj8WCiIj0YrEgIiK9WCyIiEgvFgsiItKLxYKIiPRi\nsaAWzdraGtnZ2Xd9/tlnn8Vbb73VpGukpqbCzc2tSe/RVGrIQKaNxYJUx8PDA+3atYO1tbXuNmfO\nHKNcq7i4GB4eHnd9/h//+AdeffVVo1xbKyEhAQEBAejUqRMcHBwwcuRIXQGLjY2FlZVVre/Fe++9\nZ9Q8Tz31FF577TWjXoNMj6XSAYj+SKPRICkpCSNGjFA0R1VVFSwsjPv71O+//47p06fjhx9+wPDh\nw1FSUoItW7agVatWAOT3Ijo6Gl9++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EL59EVP9jPVDYQEZGJ\nM/liERsbe8eKRHf36sV5X2A6fj9tAZw+3fzhiIhUJDU1FbGxsY36XLNbwa1lYQEIAdihEMOwE5/8\nv6Nw+vjVZk5IRKQ+Lf7wo5rs7ICrV6vvj7PYiB/LwgBLk98Oi4ioSbjdRw2ZmbJ1oXVR44S8+BTl\nAhERmTCzbVkAQE4O4Okpu6MA
}
],
"prompt_number": 18
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Return values for the GEV distribution"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"T = logspace(1,5,10);\n",
"sT = Y5gev.isf(1./T);\n",
"\n",
"\n",
"clf\n",
"semilogx(T,sT,T,sTlo,'r',T,sTup,'r'), hold\n",
"N=1:length(Y5M); Nmax=max(N);\n",
"plot(Nmax./N,sort(Y5M,'descend'),'.')\n",
"title('Return values in the GEV model')\n",
"xlabel('Return priod')\n",
"ylabel('Return value') \n",
"grid on "
],
"language": "python",
"metadata": {},
"outputs": []
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import wafo.stats as ws\n",
"R = ws.genpareto.rvs(-0.5,size=100);\n",
"phat = ws.genpareto.fit2(R[R>.5], -.5, scale=1, floc=0.5)\n",
"phat.plotfitsummary()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYwAAAEfCAYAAABSy/GnAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzsnXdYFFfXwH8LIkpERUQFAUFQEQExgsSCgr0A+pFYsKNi\n9I01GpMYE1ATW6JvonljexUjNowmL/YYC/YuauwaQeyKgIIo9X5/bJiAlF1gYRed3/PsA7tz59wz\nM2fmzC3nXIUQQiAjIyMjI6MCPW0rICMjIyNTPpAdhoyMjIyMWsgOQ0ZGRkZGLWSHISMjIyOjFrLD\nkJGRkZFRC9lhyMjIyMiohewwdBBjY2NiYmIK3D569Gi+/vrrEtURGRmJ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ff87XX3+NiYkJCxYskH4fPHgwf/75JwMHDlR5HO3atcPe3p6OHTvyySef\n0LFjR6me7LoaNWrEmjVrGDt2LGZmZmzfvp2tW7dKYyMF6fEmoRA6OpL44sUL/vWvf2FoaIiXlxf9\n+/fXtkoaIzAwEEtLS2bOnKltVUodW1tbVqxYofX4FZm3j7CwMJYvX87BgwcLLBMTE0P9+vXJyMgo\n9fimNwGdPUO//vorffr0YdmyZWzZskXb6mgUHfXRMhpg2LBh1K5dG2dn5wLLREZG0qxZM5ycnPDy\n8io75d4iUlJS+M9//sPIkSO1rcobRZk6jIJupl27duHg4ECDBg2YO3cuoOzrzJ65UFDfZXmlKF06\nMuWLwMBAdu3aVeD2xMREPvro
}
],
"prompt_number": 13
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"# Better CI for phat.par[i=0] shape parameter\n",
"Lp0 = phat.profile(i=0, pmin=-1,pmax=1)\n",
"Lp0.plot()\n",
"phat0_ci = Lp0.get_bounds(alpha=0.1)\n",
"print 'phat0_ci = ', phat0_ci\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"phat0_ci = [-0.73845586 -0.30183734]\n"
]
},
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAZYAAAEXCAYAAACOFGLrAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3XlYlFX/x/H3gEtpblluuGCpIMhmYi5pmKDlguZSLqmV\nWi5ppZXarwyXyFJb1FZLyzRxScXl0cTHsLIUzS0lwwWEABV3BRXR8/vj5DwSiwMMc88M39d1cSkz\nwz2fM+h859znPueYlFIKIYQQwkpcjA4ghBDCuUhhEUIIYVVSWIQQQliVFBYhhBBWJYVFCCGEVUlh\nEUIIYVVSWITT2rp1Kw0bNqRixYpERkbSqVMnvv32WwC+/vpr2rRpU6jjBgUF8dVXXxU5X1hYGAMG\nDAAgMTGRChUqcPPq/8I+x60/t2j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M\nHKjfoBs3NjqZ5X77Dd5/HzZv1tlHjdKFUQhbksKSDyksJYNSsGYNvPQSeHrCsGHw2GNQurTRyQov\nIQFmz4avv4b27fVpspYtjU4lSgopLPmQwuL8Dh3SBeXIEZg1Sw+EO5OLF3UP7KOPoFo1GDMGevUy\ndnxIOD8pLPmQwuK80tMhPBw+/xzGjYMXX9STEp3V9et6kD88HO64Q7fby8voVMJZWeu9Uz7/CIeg\nFCxbpsdNEhL0PJRXX3XuogL6SrHHH4dt26BvXz0X5o034PJlo5MJkTfpsQi7Fxurr5g6cQLmzNFv\nriVVSoo+Bbh7N3z6KQQHG51I
}
],
"prompt_number": 14
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"# Better CI for phat.par[i=2] scale \n",
"Lp2 = phat.profile(i=2,pmin=0.1,pmax=2)\n",
"Lp2.plot()\n",
"phat2_ci = Lp2.get_bounds(alpha=0.1)\n",
"print 'phat2_ci = ', phat2_ci\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"phat2_ci = [ 0.55127823 0.97075832]\n"
]
},
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAZIAAAEXCAYAAACH/8KRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xdc1WX7wPHPEUdZDjInoJgLQZYrxTRM0VxortQyy7Qc\njSe10krD8ZC/HOXIfLI0TXNQGm6ljCxHDswGmVtQUDEHCiki9++PO08QIId1vmdc79eLV3DOl++5\nbrVznfu6l0kppRBCCCEKqITRAQghhLBvkkiEEEIUiiQSIYQQhSKJRAghRKFIIhFCCFEokkiEEEIU\niiQS4bB27NhBvXr1KF++PJGRkXTu3JnPPvsMgE8//ZTWrVsX6L7BwcF88sknhY4vLCyMgQMHAhAX\nF0e5cuW4PRu/oK+R+feWLVtGx44dzc+VKFGC48ePFzruvDz99NOMHz++2F9H2A5JJMKmeHp6UrZs\nWcq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iSSTCSR2K6vv4bXXwcX\nF3j3XbD3cvOhQ/D++zox9uqleyk+PkZHJUTBSCLJRBKJ7fnpJ51Ajh/XpazevcGRjvVOStJlug8+\ngMBAGDVKz/pypDYKxyeJJBNJJLbj5El46y3dExk/Hp57DkqVMjqq4nP9Onz+Ocycqds5axa0aWN0\nVEJYpqDvnTLvRBSLK1f0p/ImTaBuXThyBEaOdOwkAno9y+DB8MsvegzoySf1gPzZs0ZHJkTxkUQi\nitwvv0DTpnqLkt9+0+u3ypUz
}
],
"prompt_number": 15
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"SF = 1./990\n",
"x = phat.isf(SF)\n",
"\n",
"# CI for x\n",
"Lx = phat.profile(i=2, x=x, link=phat.dist.link)\n",
"Lx.plot()\n",
"x_ci = Lx.get_bounds(alpha=0.2)\n",
"print 'X_c = ', x_ci"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"X_c = [ 1.78350616 2.09079614]\n"
]
},
{
"output_type": "stream",
"stream": "stderr",
"text": [
"c:\\pab\\workspace\\pywafo_svn\\pywafo\\src\\wafo\\stats\\distributions.py:4011: RuntimeWarning: invalid value encountered in true_divide\n",
" return where((c != 0) & (-inf < log_sf), expm1(-c * log_sf) / c, -log_sf)\n"
]
},
{
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAZIAAAEXCAYAAACH/8KRAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xl8zNf+x/HXZEFJEFpBIo3WEkQkEQkqJAi1xdoWt4qW\nKm114dfiuq2taEvvVb3dXJRS2thiqaAq1NbY3dZaWyISlRIkQhI5vz++P/NDEhmZyXxnJp/n45FH\nMjPf+c47eTCfOed8zzkGpZRCCCGEKCYnvQMIIYSwb1JIhBBCmEUKiRBCCLNIIRFCCGEWKSRCCCHM\nIoVECCGEWaSQCIe1Y8cO6tatS8WKFYmNjaVz5858++23AHz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WZCeHh0L271r1qDb/+CmPHagVsxgzo3BlkozshSo/ivndK\nIbFBSsFzz0H58jB/vnXfzJXSurxGjQJfX/jXv+D/tkcXQjg46dpyIPPnw7Fj2piItVsEBoPWEjl8\nGKKioFUrGD8esrKsm0MIYT+kRWJjkpOhSROIjwd/f73TwIUL8OabsH8/fPUVtGundyIhREmRrq27\n2HMh6dcPnnwSpkzRO8m91q6FESOgQwdt/KRyZb0TCSEsTbq2HMD27bBzJ4wbp3eS/Lp2hd9+A2dn\nCAiAYmxvLoRwUNIisSFt28Lzz8OLL+qd5ME2bYIhQ7TLhz/+GCpU0DuREMISpEVi57ZuhXPnYMAA\nvZMULSoKDh2CjAwICoJCNrMU
}
],
"prompt_number": 16
},
{
"cell_type": "code",
"collapsed": false,
"input": [],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 16
}
],
"metadata": {}
}
]
}