forked from ScoDoc/ScoDoc
nan dans les moyennes de modules (UE non évaluées)
This commit is contained in:
parent
0d75d64e85
commit
4d6d7ad168
@ -152,7 +152,7 @@ class ResultatsSemestreBUT:
|
||||
mod_idx = self.modimpl_coefs_df.columns.get_loc(mi.id)
|
||||
# moyennes indicatives (moyennes de moyennes d'UE)
|
||||
moyennes_etuds = np.nan_to_num(
|
||||
self.sem_cube[:, mod_idx, :].mean(axis=1),
|
||||
np.nanmean(self.sem_cube[:, mod_idx, :], axis=1),
|
||||
copy=False,
|
||||
)
|
||||
d[mi.module.code] = {
|
||||
@ -165,7 +165,8 @@ class ResultatsSemestreBUT:
|
||||
moduleimpl_id=mi.id,
|
||||
),
|
||||
"moyenne": {
|
||||
"value": fmt_note(self.sem_cube[etud_idx, mod_idx].mean()),
|
||||
# moyenne indicative de module: moyenne des UE, ignorant celles sans notes (nan)
|
||||
"value": fmt_note(np.nanmean(self.sem_cube[etud_idx, mod_idx])),
|
||||
"min": fmt_note(moyennes_etuds.min()),
|
||||
"max": fmt_note(moyennes_etuds.max()),
|
||||
"moy": fmt_note(moyennes_etuds.mean()),
|
||||
|
Loading…
Reference in New Issue
Block a user