Added proper Exception in statepoint Python scripts.

This commit is contained in:
Paul Romano 2012-08-24 11:13:53 -04:00
parent 84f2974459
commit b5a8c047e5
2 changed files with 2 additions and 2 deletions

View file

@ -20,7 +20,7 @@ sp = StatePoint(filename)
# Check if tallies are present
if not sp._get_int()[0]:
print("No tally data in state point!")
raise Exception("No tally data in state point!")
# Calculate t-value for 95% two-sided CI
n = sp.current_batch - sp.n_inactive

View file

@ -21,7 +21,7 @@ sp = StatePoint(filename)
# Check if tallies are present
if not sp._get_int()[0]:
print("No tally data in state point!")
raise Exception("No tally data in state point!")
# Calculate t-value for 95% two-sided CI
n = sp.current_batch - sp.n_inactive