MartinSpindler / hdm

Other
11 stars 8 forks source link

Fix Iteration for poly_order > 1 #12

Open PhilippBach opened 10 months ago

PhilippBach commented 10 months ago

One thing we should take care of is if the poly_order is set to 0 ... Then this loop here doesn't make sense

https://github.com/MartinSpindler/hdm/blob/d9fe0f09a39a32959f0344632b0dda25197b9dd2/R/AutoDebiased_backends.R#L178

@klosins - do you think it makes sense to generally require poly_order > 1. Otherwise, the derivative is constant anyways...

Otherwise, we'd have to include another if (poly_order == 1) condition here

klosins commented 10 months ago

@PhilippBach I think it makes sense to require that poly >1 -- because that is the case when classic linear model is used, which would likely the most simple model that applied people would want to try I think. I will be working on the package today - trying to figure out the data.table warning

PhilippBach commented 9 months ago

@klosins and I agreed that allowing for poly == 1 would implement a standard benchmark, so we should allow and handle this case explicitly