diff --git a/main/astrodatagui/ui/FlaredetectorWidget.py b/main/astrodatagui/ui/FlaredetectorWidget.py index cb442d6..789d892 100644 --- a/main/astrodatagui/ui/FlaredetectorWidget.py +++ b/main/astrodatagui/ui/FlaredetectorWidget.py @@ -8,7 +8,8 @@ from astropy.visualization import time_support import lightkurve as lk from ...flaredetector.util import (findMaxIndices, plotFlarePeaks, - plotFlareFits, markFlare) + plotFlareFits, markFlare, + convertStarndardIndexToFoldedIndex) from ...flaredetector.flaredetector import calculateFlareFitsForLightcurve class FlaredetectorWidget(QtWidgets.QWidget): @@ -242,6 +243,10 @@ class FlaredetectorWidget(QtWidgets.QWidget): time_support() if(self.FoldState["Enabled"]): lc.scatter(label=label, ax=self.figureAxis) + for peak in self.peaks: + cycle, foldedIndex = convertStarndardIndexToFoldedIndex(lc, peak["StandardIndex"]) + self.figureAxis.plot(lc.phase[lc.cycle == cycle][foldedIndex].value, + lc.flux[lc.cycle == cycle][foldedIndex], "x", color="red") elif(self.PeriodogramState["Enabled"]): lc.plot(label=label, ax=self.figureAxis, view=self.PeriodogramState["View"]) if(self.PeriodogramState["View"] == "period"):