FK83 / scoringRules

scoring rules to evaluate probabilistic forecasts
53 stars 16 forks source link

energy score #47

Closed kashif closed 4 years ago

kashif commented 4 years ago

Hello! I was wondering if the 2* is needed in this line when calculating the pairwise distances:

https://github.com/FK83/scoringRules/blob/f7630ac01aa710fb021f84b0b2132649ac452cda/src/procs_es.cpp#L26

Since otherwise it gets canceled by the 2 * here:

https://github.com/FK83/scoringRules/blob/f7630ac01aa710fb021f84b0b2132649ac452cda/src/procs_es.cpp#L30

slerch commented 4 years ago

The 2* in line 26 is required due to the loop structure (the inner loop in line 25 starts at j = i). It is possible to remove both the 2*' in lines 26 and the one in line 30.

kashif commented 4 years ago

right thanks @slerch missed that! Thanks!