Learn R Programming

strvalidator (version 1.3.0)

export: Export

Description

export exports or saves various objects.

Usage

export(object, name = NA, useObjectName = is.na(name),
  env = parent.frame(), path = NA, ext = "auto", delim = "\t",
  width = 3000, height = 2000, res = 250, overwrite = FALSE,
  debug = FALSE)

Arguments

object
string, list or vector containing object names to be exported.
name
string, list or vector containing file names. Multiple names as string must be separated by pipe '|'. If not equal number of names as objects, first name will be used to construct names.
useObjectName
logical, if TRUE file name will be the same as object name.
env
environment where the objects exists.
path
string specifying the destination folder exported objects.
ext
string specifying file extension. Default is 'auto' for automatic .txt or .png based on object class. If .RData all objects will be exported as .RData files.
delim
string specifying the delimeter used as separator.
width
integer specifying the width of the image.
height
integer specifying the height of the image.
res
integer specifying the resolution of the image.
overwrite
logical, TRUE if existing files should be overwritten.
debug
logical indicating printing debug information.

Value

  • NA if all objects were exported OR, data.frame with columns 'Object', 'Name', and 'New.Name' with objects that were not exported.

Details

Export objects to a directory on the file system. Currently only objects of class data.frames or ggplot are supported. data.frame objects will be exported as '.txt' and ggplot objects as '.png'. .RData applies to all supported object types.