metadataSweepImport: Import data with a prepared metadata sweep session

View source: R/metadataSweepImport.R

metadataSweepImportR Documentation

Import data with a prepared metadata sweep session

Description

Import a dataset and immediately prepare metadata for a declared consumer profile. The returned session remains reusable for every profile; prepare controls only which projection is warm when the import returns.

Usage

metadataSweepImport(
  from,
  revision,
  prepare = "progressive",
  columns = NULL,
  fields = NULL,
  xml_options = list(),
  ...
)

Arguments

from

Path to a dataset supported by convert().

revision

One non-missing atomic revision token for the imported data.

prepare

One of "progressive", "dialogr", or "codebook".

columns

Integer positions or unambiguous variable names to prepare. NULL prepares every column. Progressive consumers should provide their initial visible range.

fields

Optional field groups passed to metadataSweepRead().

xml_options

Named arguments passed to the variable XML generator.

...

Import arguments passed to convert(). The import destination is always R; to must not be supplied.

Value

An object with data, session, and the prepared projection. Close session with metadataSweepClose() when it is no longer needed.

Examples

## Not run: 
imported <- metadataSweepImport(
    "survey.sav",
    revision = 1L,
    prepare = "progressive",
    columns = 1:20
)
metadataSweepClose(imported$session)

## End(Not run)


DDIwR documentation built on Oct. 8, 2026, 9:06 a.m.