Load FindTheTail

[1]:
import findthetail.ftt as ftt
import pandas as pd
import numpy as np
[2]:
# disable warning to keep the output clean
# the warning result form divergences in the logarithms in the test statistics
np.warnings.filterwarnings('ignore')

Read data

[3]:
river_nidd_data = pd.read_csv('data/river_nidd_data.csv', names=['x'])

Load data into model and run analyse

[4]:
# instanciate the Ftt (Find the tail) class with data,
# number of mc steps and a name for the report
mod = ftt.Ftt(river_nidd_data['x'].values, mc_steps=500, data_name='River Nidd')
mod.run_analysis()
Runnig fit
Running Montecarlo simulation
Calculating q and cvar
Generating plots

Generate report

[5]:
mod.report_html()

The report can be found here