padpadpadpad / rTPC

R package to help fit Thermal Performance Curves
https://padpadpadpad.github.io/rTPC/
22 stars 3 forks source link

Confusion over get_eh in TPCs #57

Closed HaleyAddison closed 2 weeks ago

HaleyAddison commented 1 month ago

Hi Daniel,

I have been using your rTPC package and I am at the point that I have a model and I am aiming to estimate parameters.

My plot is showing that species B clearly has a higher Eh, and when I view my nls linear models, this is reflected. However, when I use either calc_params or get_eh, the eh estimates are dramatically different and B is no longer higher than other species. Can you explain why this is? would it be accurate to just show the eh values reflected when viewing my models??

Thank you

padpadpadpad commented 1 month ago

Hi Haley

Was the model you were using explicitly modelling the deactivation energy (eh). If so then that is going to be a much better estimate than that from get_eh().

get_eh() estimates the deactivation energy by subsetting all the raw data for points beyond the optimum, and then fitting a Boltzmann equation to it. This means sometimes there may be only 1 or 2 points beyond the optimum, which would likely result in a poor fit.

If you want values for the deactivation energy, I would generally recommend fitting a model that estimates it explicitly.