Half Life Plot

Download the full notebook.

half_life_plot

Half-life Plot

In [61]:
import numpy as np
%matplotlib inline
import matplotlib
matplotlib.rc('font', family='serif', size=14)
import matplotlib.pyplot as plt
from pyne import nucname, nuc_data

import tables as tb
f = tb.open_file(nuc_data)
ids = []
for index, value in enumerate(f.root.decay.level_list[:]['nuc_id']):
    ids.append(int(value))
anums = map(nucname.anum, ids)
#anums = map(nucname.anum, data.half_life_map.keys())
In [62]:
fig = plt.figure(figsize=(7,7))
plt.semilogy(list(anums),  ids, 
             'o', alpha = 0.05, markerfacecolor=None, markeredgecolor = 'k')
plt.xlabel('A')
plt.ylabel('Half-life [s]')
Out[62]:
Text(0, 0.5, 'Half-life [s]')