Open slwu89 opened 1 year ago
Ch 8 of this book https://psplines.bitbucket.io/ claims that the Pya and Wood code implementation is wrong and that https://cran.r-project.org/web/packages/cgam/index.html is correct. I haven't looked at these claims or the "cgam" package in detail yet.
Interesting functions that seem relevant: https://www.stat.colostate.edu/~meyer/code.htm
Wood and Pya (https://link.springer.com/article/10.1007/s11222-013-9448-7) present a method to set up constraints on P-splines (monotonic, convex/concave, etc). These kinds of constraints, along with max/min constraints would be very helpful for using these to fill in unknown functions in mechanistic models! For example, mosquito feeding rate should increase with increasing host density, but cannot exceed some maximum rate given by digestion/handling time.