Export from csv to Zotero

Hi guys,

I needed to export my library from Zotero into R to make a random sampling. After sampling, I want to re-import the library again into Zotero. Does anybody know how to import the csv file into Zotero? Or would you suggest to use another format?
Any suggestions would be highly appreciated.

regards,
Lisa Muessig
  • you can't really re-import csv. How large a sample are we talking? My initial approach would be to just place the sampled items in a collection in Zotero, keeping the original library intact.
  • thank you for the fast response!
    I guess re-importing the csv file would have been too easy. Is there another option how to make a random sampling?
    It is a literature analysis, so I need to randomly sample 4000 papers out of 100.000. I managed to create a csv file with the sampled papers, but I want to import it back into Zotero.
  • edited June 19, 2016
    (Not sure on the best way to handle this with current functionality, but this would be a great plugin feature to assign 0/1 values to the Extra field to a random proportion of items in a collection/library. It would be probably be fairly to simple to build such a plugin based on the Zotero Scholar Citations plugin, replacing the citation count scripts for a simple weighted number generator. I don't have time to write this, but if you have any skill with javascript it would be doable, or you might be able to ask one of the developers of other plugins.)


    Edit:
    You could also do this using batch editing in Zotero for Firefox. Install the Execute JS Firefox plugin. Then, you can use a script like this one here: https://gist.github.com/bwiernik/3e515f368872943ec12de524753217d7

    That script assigns a value of 0 or 1 to the Call Number field of each item in a collection or saved search according to a specified probability. (I haven't tested it, but it should work fine).
Sign In or Register to comment.