jkcshea / ivmte

An R package for implementing the method in Mogstad, Santos, and Torgovitsky (2018, Econometrica).
GNU General Public License v3.0
18 stars 2 forks source link

Error when error with bounds #232

Closed johnnybonney closed 1 year ago

johnnybonney commented 1 year ago

When estimating with the "hard" constraints approach, and there is an underlying error with obtaining the bounds, I get output/error like this:

Performing audit procedure...
    Solver: Gurobi ('gurobi')
    Criterion constraint: Hard, l1 norm 
    Generating initial constraint grid...

    Audit count: 1
    Minimum criterion: 1.939618e-06
    Obtaining bounds...
Error in audit(vars_data = vars_data, initgrid.x = list(village_id = c(1L,  : 
  object 'minoobseq' not found

This seems to be due to a typo (it's the only time minoobseq appears, as opposed to minobseq), which occurs here: https://github.com/jkcshea/ivmte/blob/31a7427a591206f83bd76fad542934d5fd491d63/R/audit.R#L1068

(This is such a small issue that I would fix it myself, but I'm not super experienced with collaborating on git and don't want to cause more problems than I would be solving!)

jkcshea commented 1 year ago

No problem, it's fixed!