elizagrames / litsearchr

litsearchr is an R package to partially automate search term selection for systematic reviews using keyword co-occurrence networks. In addition to identifying search terms, it can write Boolean searches and translate them into over 50 languages.
https://elizagrames.github.io/litsearchr
103 stars 26 forks source link

issue reading in file #33

Closed johnaeanderson closed 4 years ago

johnaeanderson commented 4 years ago

Hi Eliza,

I've tried importing some data using the following code:

`library(litsearchr)

search_directory <- "/Users/john/Documents/Litearature_Searches/Bilingualism_Functional_Connectivity/"

naiveimport <- litsearchr::import_results(directory = search_directory, verbose = TRUE)`

I'm getting this error: Error in read.table(text = x, header = TRUE, sep = "\t", quote = "\"", : duplicate 'row.names' are not allowed

I think this is an issue with data.table? Any help would be appreciated!

John

johnaeanderson commented 4 years ago

... as an update, this seems to work fine with RIS imports from scopus - so maybe it's something weird about web of science in particular?

elizagrames commented 4 years ago

Yeah, there is something odd happening with read.table for .csv and .tsv from Web of Science. I think I just fixed this by bug by setting row.names to NULL when importing .tsv and .csv text files. You'll have to re-install synthesisr (the dependency that handles import) for the fixed functions.

johnaeanderson commented 4 years ago

Hi Eliza,

Still not quite working, but I've managed a workaround which is to import a bibtex file from Web of Science to Zotero & output an RIS which is read fine.

Thanks again,

J

elizagrames commented 4 years ago

Hmm, that's odd. Somebody else had the same issue and said the fix worked for him, so it must be some nuance in how Web of Science files are exported and I don't know what the difference in file types is so I may have misinterpreted your original issue.

I am going to keep this issue closed for now and advise anyone reading this to re-read files through Zotero like John did, but will keep trying to figure out why some WoS files won't parse.