sbailey / surveyqa

DESI Survey QA Dashboard
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Skypath moon #67

Open sbailey opened 5 years ago

sbailey commented 5 years ago

Trying new PR. @rdoshi99 does this contain all the commits it should?

rdoshi99 commented 5 years ago

Yeah, this looks right. I am adding a comment with the description of the PR

rdoshi99 commented 5 years ago

Created a sine function to approximate the phase of the moon through the getPhase function

helper functions include: phaseSign which determines if the moon phase is waxing waning toDatetime which converts a night into a datetime object (perhaps this function should be merged) numNightsFullZero (which calculates the number of days which have passed since a specific full moon on Nov. 11, 2019) getWedge which, given the phase of the moon, plots a point onto the figure (from skypath plot) as either a ring, wedge, or full circle depending on the phase of the moon

This also adds a label to the top of the skypath plot with the fraction of the moon illuminated

This addresses issue #27

and the attached image shows the model with rough approximations from hand calculations https://user-images.githubusercontent.com/46800082/56942231-55fd9480-6ace-11e9-95ba-3dca439181c0.png

rdoshi99 commented 5 years ago

The other comment I have is that I added the label for moon fraction but I could not get it to align right on the plot: https://user-images.githubusercontent.com/46800082/56942266-90673180-6ace-11e9-8beb-9405d3798ceb.png This is because the Label annotation on bokeh doesn't support the same type of align as Title does I tried adding a second Title and this was the result: https://user-images.githubusercontent.com/46800082/56942293-b7256800-6ace-11e9-803e-27ff6cad2cd3.png Where the actual plot title gets pushed up farther above, which I thought would mess with the styling already done