add heatmap plot for term report
This commit is contained in:
parent
aa7d77383e
commit
59cd8e2aba
|
@ -8,6 +8,8 @@ from notes_tools.tools.marks_plottings import (pie_pivot_table,
|
|||
radar_on,
|
||||
)
|
||||
|
||||
import seaborn as sns
|
||||
|
||||
__all__ = ["students_pov", "class_pov"]
|
||||
|
||||
class Student(object):
|
||||
|
@ -98,6 +100,22 @@ class Student(object):
|
|||
"Domaine")
|
||||
return self._radar_on_domaine
|
||||
|
||||
@property
|
||||
def heatmap_on_domain(self):
|
||||
""" Heatmap over evals on domains """
|
||||
try:
|
||||
self._heatmap_on_domain
|
||||
except AttributeError:
|
||||
comp = pd.pivot_table(self.quest_df,
|
||||
index = "Competence",
|
||||
columns = ["Date","Nom"],
|
||||
values = ["Normalized"],
|
||||
aggfunc = np.mean,
|
||||
)
|
||||
comp.columns = [i[1].strftime("%Y-%m-%d") + "\n" + i[2] for i in comp.columns]
|
||||
self._heatmap_on_domain = sns.heatmap(comp)
|
||||
return self._heatmap_on_domain
|
||||
|
||||
|
||||
def parallel_on_evals(self, classe_evals):
|
||||
""" Parallel coordinate plot of the class with student line highlight """
|
||||
|
|
Loading…
Reference in New Issue