Skip to content

Commit

Permalink
Remove dependency on gatspy
Browse files Browse the repository at this point in the history
  • Loading branch information
mwcraig committed Oct 27, 2023
1 parent 5d73d59 commit d7dfdf7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
1 change: 0 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ install_requires =
photutils >=1
matplotlib
pandas
gatspy
pyyaml
astrowidgets
ipyfilechooser
Expand Down
15 changes: 8 additions & 7 deletions stellarphot/visualization/multi_night_plots.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@

from astropy.stats import mad_std
from astropy.time import Time

from gatspy.periodic import LombScargleFast
from astropy.timeseries import LombScargle


__all__ = ['plot_magnitudes', 'multi_night']
Expand Down Expand Up @@ -201,11 +200,13 @@ def multi_night(sources, unique_nights, night,
np.isinf(mag_err[source.id - 1]))
bads = bad_mags | bad_errs
good_mags = ~bads
model = LombScargleFast().fit(source.bjd_tdb[good_mags],
mags[source.id - 1][good_mags],
mag_err[source.id - 1][good_mags])
periods, power = model.periodogram_auto(nyquist_factor=100,
oversampling=3)
ls = LombScargle(source.bjd_tdb[good_mags],
mags[source.id - 1][good_mags],
mag_err[source.id - 1][good_mags])

freqs, power = ls.autopower(nyquist_factor=100,
samples_per_peak=10)

max_pow = power.max()

# print(source, max_pow)
Expand Down

0 comments on commit d7dfdf7

Please sign in to comment.