'''Browse plot for JUICE preliminary orbit
'''
import os
import sys
import logging
logging.basicConfig()
import datetime
import math
import matplotlib.pyplot as plt
import numpy as np
import scipy as sp
import pyana.pep.juice_spice
def main():
# Coverage comes from mantra.jgo_2020_001_ipc_cal_pso_res_e40_562_200.bsp
t0 = datetime.datetime(2020, 3, 8, 11, 40)
t1 = datetime.datetime(2029, 7, 25, 0, 30)
dt = datetime.timedelta(days=1)
j = pyana.pep.juice_spice.JuiceSpice.get_default_instance()
tlist = []
t = t0
while t <= t1:
tlist.append(t)
t = t + dt
pos = j.get_positions(tlist)
fig = plt.figure()
ax = fig.add_subplot(111)
ax.plot(pos[:, 0], pos[:, 1], '-x')
return pos
if __name__ == '__main__':
main()