Fix bug in id_var when factor levels missing
Ignore rhistory
Fix another problem with missing levels