ReadForAnalysisfromTotal: Read the dataset/NARCIS-dump stored locally

Description Usage Arguments Value

Description

Assumed is that "OAI Harvest New Records.R" has been run, and results are stored on disk

Usage

1
2
3
4
ReadForAnalysisfromTotal(Summarize = FALSE, FilePath = "Auto",
  set = "auto", ForceReload = FALSE, verbose = TRUE, DropCols = NULL,
  KeepCols = NULL, KeepSets = NULL, KeepMulti = NULL,
  assignTo = .GlobalEnv)

Arguments

Summarize

Should the entire dataset be loaded, or just the summary. Can be FALSE, TRUE or 'Only'. In the last case, the script looks if there is a summarizing file, and loads that if there is one. Otherwise, one is created. If TRUE, the entire set is also loaded and stored (assigned to assignTo-environment), but nothing is done with any present summaryfile. To update the summaryfile, simply remove it, and run this function again with Summarize=='Only'

FilePath

Link to file, or 'Auto'. If Summarize=='Only', provide link to summary file.

set

Which set to open. Can be 'dc', 'auto', or 'didlmods'. Auto opens the last stored set. Note that at current implementation, opening didlmods is of little use, the mongo-db-access is more useful. Also note that as of june 2018, OAI Harvest New Records.R does not store a totalfile for didlmods, so 'auto' defaults to dc.

ForceReload

Should the file always be reloaded? If FALSE, script first looks if a variable called 'Total' exists in the global environment, and reuses that if it does, which saves loading time.

verbose

Emit status messages?

DropCols, KeepCols

Columns to drop or keep form the totalSet. If both are defined, DropCols is ignored

KeepSets

Select to use only certain sets.

KeepMulti

Additional selection criteria, in the form of a named list with allowed values. E.g. list(Type==c('Article', 'Doctoral thesis'))

assignTo

As a side-effect, the "total" data.frame and Paths variable are stored. Where should they be stored?

Value

If Summarize==TRUE or Summarize=='Only' a data.frame with counts. If Summarize==FALSE, invisible 0. Side-effects: Assignment of 'Total' to the global environment, along with modification of 'Paths' global environment if it exists: The slots loadedWerkset and loadedWerkSummary are adapted if they are used. Be careful that loadedWerkset is not updated if Summarize=='Only', and loadedWerkSummary is not updated of Summarize==FALSE.


EmilBode/NARCISOAFunc documentation built on May 15, 2019, 1:57 a.m.