Skip to content

Commit b672834

Browse files
committed
fix typo in printing rates u = 1**-6
also close the file when we are done
1 parent 697ab66 commit b672834

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

examples/nugen_nuflux.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ def northern_track(energy: ArrayLike) -> ArrayLike:
4343
NAME = getattr(flux_model, "name", "Northern Track 9.5 year")
4444

4545
# print the total rate of each model
46-
print(f"{NAME:26} {1e6 * weights.sum():8.2f} mHz")
46+
print(f"{NAME:26} {1e6 * weights.sum():8.2f} uHz")
4747

4848
# histogram the primary energy with the weights
4949
plt.hist(primary_energy, weights=weights, bins=bins, histtype="step", label=NAME)
@@ -58,3 +58,5 @@ def northern_track(energy: ArrayLike) -> ArrayLike:
5858
plt.xlim(bins[0], bins[-1])
5959
plt.savefig("nugen_nuflux.svg")
6060
plt.show()
61+
62+
hdffile.close()

0 commit comments

Comments
 (0)