sashahafner / biogas

Tools for biogas research in R: process biogas data and predict biogas production
14 stars 4 forks source link

calcBgVol() problem with fixed xCH4/comp #44

Open sashahafner opened 3 years ago

sashahafner commented 3 years ago
dat <- calcBgVol(dat, comp = 0.65, comp.name = 'xCH4', temp = 'temp.c', pres = 'pres.hPa', data.struct = 'long',
                 id.name = 'channel', time.name = 'time.d', vol.name = 't.vol', unit.pres = 'hPa')

will not work (gives useless error) without comp.name. Although DataPrep function has default for comp.name, call in calcBg will send in NULL and so there is no place to put xCH4/comp in the returned data frame. So DataPrep has to check for null with comp exists and use a default name xCH4.