write_JabRef_Config.Rd
This function writes one or more JabRef configuration files that set a number of fields to be visible to screeners, so that you can mask the screeners from fields like journal, authors, and publication year.
write_JabRef_Config(
outputPath,
screeners = c("a", "b"),
screenerFieldsPrefix = "screener",
screenerFieldsSuffix = "status",
screenerConfidencePrefix = "screener",
screenerConfidenceSuffix = "confidence",
fields = c("title", "abstract"),
duplicateField = NULL,
sortField = "title",
sortDesc = FALSE,
screeningType = "screening",
jabrefVersion = "2.11.1",
jabrefXML = NULL,
batFile = NULL,
generateSettingRemovalBatchFile = FALSE,
screenerSuffixInFilename = FALSE
)
The path to write the file(s) to.
The strings to use to identify the screeners.
The prefix and suffix to attach to the screener identification strings to create the fields where the screeners store their decision.
The prefix and suffix to attach to the screener identification strings to create the fields where the screeners store their confidence in their decision.
The fields that have to be screened.
The field
The field to sort entries by.
Whether to sort in descending or ascending order.
The type of screening (added to the filenames).
The version of JabRef to format the configuration file for.
Optionally, the path to a file with a jabrefXML 'skeleton', in which certain, as yet undocumented, replacements will be made (but you can check the source code of the function in the meantime).
Optionally, contents of the batch file to write.
Whether to write a batch file that edits the Windows registry to remove JabRef configuration, which may sometimes be necessary to get JabRef to use the XML configuration file.
Whether to add the screener identifier as a suffix to the file that is written.
Invisibly, an object with the configuration file and intermediate steps.
### Get the path to a temporary directory
tempPath <- tempdir();
### Write screener packages
metabefor::write_JabRef_Config(
tempPath,
screeners = "A"
);
### Load written file
jabRefConfig <-
readLines(
file.path(
tempPath,
"jabref.xml"
)
);
### Show beginning of file
cat(jabRefConfig[1:10], sep="\n");
#> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
#> <!DOCTYPE preferences SYSTEM "http://java.sun.com/dtd/preferences.dtd">
#> <preferences EXTERNAL_XML_VERSION="1.0">
#> <root type="user">
#> <map/>
#> <node name="net">
#> <map/>
#> <node name="sf">
#> <map/>
#> <node name="jabref">
### Show bit in the middle with specific screening info
cat(jabRefConfig[39:41], sep="\n");
#> <entry key="customTabName_0" value="Screening"/>
#> <entry key="customTabFields_0" value="title;abstract;screenerAstatus;screenerAconfidence"/>
#> <entry key="columnNames" value="title;abstract;screenerAstatus"/>