Skip to content

Commit

Permalink
Add comment about ddof
Browse files Browse the repository at this point in the history
  • Loading branch information
maxnoe committed Jun 18, 2018
1 parent 07bffe6 commit e289b11
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ctapipe/image/hillas.py
Original file line number Diff line number Diff line change
Expand Up @@ -704,6 +704,9 @@ def hillas_parameters_5(geom: CameraGeometry, image):
delta_x = pix_x - cog_x
delta_y = pix_y - cog_y

# The ddof=0 makes this comparable to the other methods,
# but ddof=1 should be more correct, mostly affects small showers
# on a percent level
cov = np.cov(delta_x, delta_y, aweights=image, ddof=0)
eig_vals, eig_vecs = np.linalg.eigh(cov)

Expand Down

0 comments on commit e289b11

Please sign in to comment.