pgu.file: pgu.fie

Description Format Details Active bindings Methods Author(s)

Description

Handles file names for the pguIMP shiny web interface.

Format

R6::R6Class object.

Details

The class stores filenames and upload specifications for the pguIMP shiny web interface in its instance variables. This object is used by the shiny based gui and is not for use in individual R-scripts!

Active bindings

uploadFileName

Returns the instance variable uploadFileName (character)

fileName

Returns the instance variable fileName (character)

baseName

Returns the instance variable baseName (character)

folderName

Returns the instance variable folderName (character)

suffix

Returns the instance variable suffix (character)

exportSuffix

Returns the instance variable exportSuffix (character)

timeString

Returns the instance variable timeString (character)

sheetIndex

Returns the instance variable sheetIndex (numeric)

separator

Returns the instance variable separator (character)

skipRows

Returns the instance variable skipRows (numeric)

columnNames

Returns the instance variable columnNames (logical)

naChar

Returns the instance variable naChar (character)

Methods

Public methods


Method new()

Clears the heap and indicates that instance of pgu.file is removed from heap.

Splits fileName and writes the results in the class' instance variables folderName, baseName, suffix.

Stores the current system time into the instance variable timeString.

Creates and returns a new object of type pgu.file.

Usage
pgu.file$new(
  uploadFileName = "",
  fileName = "",
  sheetIndex = 1,
  separator = ",",
  skipRows = 0,
  columnNames = TRUE,
  naChar = "NA"
)
Arguments
uploadFileName

Name of uploaded file. (string)

fileName

Actual file name. (string)

sheetIndex

Index excel sheet to import. (integer)

separator

Character for column separation. (character)

skipRows

Number of rows to skip. (integer)

columnNames

Indicates if the data source file has a columnNames. (logical)

naChar

Character for missing values. (string)

Returns

A new pgu.file object. (pguIMP::pgu.file)


Method print()

Prints the instance variables of the object.

Usage
pgu.file$print()
Returns

string


Method reset()

Resets the instance variables of the object.

Usage
pgu.file$reset(
  uploadFileName = "",
  fileName = "",
  sheetIndex = 1,
  separator = ",",
  skipRows = 0,
  columnNames = TRUE,
  naChar = "NA"
)
Arguments
uploadFileName

Name of uploaded file. (string)

fileName

Actual file name. (string)

sheetIndex

Index excel sheet to import. (integer)

separator

Character for column separation. (character)

skipRows

Number of rows to skip. (integer)

columnNames

Indicates if the data source file has a columnNames. (logical)

naChar

Character for missing values. (string)


Method fit()

Extracts information about upload specifications from the instance variables.

Usage
pgu.file$fit()

Method predict()

Predicts an export file name.

Usage
pgu.file$predict(affix = "analysis")
Arguments
affix

User dedined file name affix. (string)

Returns

A file name. (string)


Method fit_predict()

Extracts information about upload specifications from the instance variables and predicts an export file name.

Usage
pgu.file$fit_predict(affix = "analysis")
Arguments
affix

User dedined file name affix. (string)

Returns

A file name. (string)


Method clone()

The objects of this class are cloneable with this method.

Usage
pgu.file$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Author(s)

Sebastian Malkusch, malkusch@med.uni-frankfurt.de


pguIMP documentation built on Sept. 30, 2021, 5:08 p.m.