dalejn / cleanBib

Probabilistically assign gender and race proportions of first/last authors pairs in bibliography entries
MIT License
149 stars 31 forks source link

Broken .bib file? #17

Closed beccabos closed 4 years ago

beccabos commented 4 years ago

hi! i am very new to using code and so appreciate you making this public. i think that something is wrong with the .bib file I exported from Mendeley- are you able to help me problem-solve? any guidance on typical errors etc would be much appreciated!!! export_fullnames.zip

dalejn commented 4 years ago

Hi! Thanks for checking out our code. Your .bib file indeed returns an error, which is a trace of the error with too much detail, and you can ignore those details and look at the last line of the error. When running the 2nd code block in the notebook cleanBib.ipynb, the error message is:

TokenRequired: syntax error in line 283: entry key expected

This suggests that something is going wrong on the 283rd line of your .bib file. Looking at the file, there's no article key for that citation:

@article{,
   author = {Josefina Castro-Fornieles and Rosa M Diaz and Javier Goti and Rosa Calvo and Laura Gonzalez and Lourdes Serrano and Antoni Gual},
   journal = {Eur Addict Res},
   pages = {61-68},
   title = {Prevalence and factors related to substance use among adolescents with eating disorders},
   volume = {16},
   year = {2010},
}

After fixing that one, I'm getting the same error for line 332. Looking at the .bib file, there's also no article key for that citation:

@article{,
   author = {Rebecca G Boswell and Carlos M Grilo},
   journal = {CNS Spectr},
   title = {General Impulsivity in Binge-Eating Disorder},
}

As in the other entries (e.g. '@article{Clark2004,'), you'll need to add a unique article key like: @article{uniqueArticleName,

beccabos commented 4 years ago

WOW! thank you so much - this worked! I am so excited to include this in my article; really appreciate it.