EOGrady21 / vprr

Video Plankton Recorder Data Processing
https://eogrady21.github.io/vprr/
Other
2 stars 1 forks source link

vpr_oce_create() - argument specifying ctd variables to add #49

Closed kevinsorochan closed 11 months ago

kevinsorochan commented 1 year ago

Is your feature request related to a problem? Please describe. Currently, vpr_oce_create() will give an error if certain "extra" ctd variables are not specified

Usage vpr_oce_create(data) Arguments data
data frame of vpr data with variable names

'time_ms', 'fluorescence_mv', 'turbidity_mv', 'n_roi', 'sigmaT'

Describe the solution you'd like The "extra" ctd variables should be able to be specified in an argument for this function. There should be no requirement for these particular variables.

EOGrady21 commented 11 months ago

When I went to solve this, I realized that (maybe due to a new version of oce?) all the variables from the dataframe are pulled within the single oce::as.ctd() call, so there is no need for the looping/ hardcoding solution I had originally used.

I put a check in just in case, if any variables were left off of the oce-ctd object it would produce a warning.