11import numpy as np
22from rstcloth import RstCloth
3- from glidertest import tools , plots , utilities
3+ from glidertest import tools , plots , utilities , __version__
44from ioos_qc import qartod
55from datetime import datetime
66import pypandoc
@@ -330,6 +330,7 @@ def create_docfile(ds, path):
330330 doc .newline ()
331331 dur = phrase_duration_check (ds )
332332 doc .content (f"Issues with profile number: { profnum } " )
333+ doc .newline ()
333334 doc .content (f"Issues with profile duration: { dur } " , )
334335 gr_strb = ['Global range' , '✓' , '✓' , '✓' , '✓' ]
335336 st_strb = ['Spike test' , '✓' , '✓' , '✓' , '✓' ]
@@ -354,7 +355,7 @@ def create_docfile(ds, path):
354355 dr_strb ,
355356 ])
356357 todays_date = datetime .today ().strftime ('%Y-%m-%d' )
357- doc .content (f'Created with glidertest on { todays_date } ' )
358+ doc .content (f'Created with glidertest version { __version__ } on { todays_date } ' )
358359
359360 return doc
360361
@@ -547,7 +548,7 @@ def create_drift_plots(ds, path):
547548 """
548549 available_sensor , available_optics , vars_optics = optics_avaialble_data (ds )
549550 for var in vars_optics :
550- fig , ax = plots .process_optics_assess (ds , var = 'CHLA' )
551+ fig , ax = plots .process_optics_assess (ds , var = var )
551552 fig_name = f'{ var } _drift.png'
552553 fig .savefig (f'{ path } /{ fig_name } ' )
553554
@@ -614,15 +615,19 @@ def create_optics_doc(ds, path):
614615 ('alt' , '' ),
615616 ('width' , '600px' )
616617 ])
618+ doc .newline ()
619+
617620 doc .h2 ('Drift' )
618621 for var in vars_optics :
619622 fig_name = f'{ var } _drift.png'
620623 doc .directive ('image' , f'./{ fig_name } ' , fields = [
621624 ('alt' , '' ),
622625 ('width' , '600px' )
623626 ])
627+ doc .newline ()
628+
624629 todays_date = datetime .today ().strftime ('%Y-%m-%d' )
625- doc .content (f'Created with glidertest on { todays_date } ' )
630+ doc .content (f'Created with glidertest { __version__ } on { todays_date } ' )
626631
627632 return doc
628633
0 commit comments