Skip to content

Commit

Permalink
Update sbe_ctd_parser.py (#238)
Browse files Browse the repository at this point in the history
  • Loading branch information
shaunwbell authored Jan 20, 2023
1 parent ba6731d commit 313d3ba
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/EcoFOCIpy/io/sbe_ctd_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,3 +146,14 @@ def parse(file_list=[None], datetime_index=True):

return (df_dic, header_dic)

@staticmethod
def PAR_calc_from_volts(rawdata_pd_series,multiplier=1.0,M=1.0,B=0.0,calconst=10**10,offset=-1):
"""
Pass the voltage channel in as a pandas series (so value,index) as well as the calculated SBE desired calibration factors
not the biospherical factors
"""

SBEDefPAR = (multiplier * (10**9 * 10**(rawdata_pd_series.values/M)) / calconst)+offset
SBECorrPAR = multiplier * ((10**9 * 10**(rawdata_pd_series.values/M)) / calconst+offset)

return(SBEDefPAR, SBECorrPAR)

0 comments on commit 313d3ba

Please sign in to comment.