to_all_interval_formats: Convert Interval Data to All Supported Formats

View source: R/interval_format_conversions.R

to_all_interval_formatsR Documentation

Convert Interval Data to All Supported Formats

Description

Convert interval data from any recognized format to all six supported interval data formats and return the results as a named list. This is useful for inspecting and comparing how the same interval data is represented across different formats.

Usage

to_all_interval_formats(x, ...)

Arguments

x

Interval data in one of the supported formats: "RSDA", "MM", "iGAP", "ARRAY", "SODAS", or "SDS".

...

Additional arguments passed to conversion functions (e.g., location for iGAP input).

Details

Six interval data formats are supported in this package. Each format stores the same information – lower and upper bounds for every variable of every observation – but differs in its structure and origin:

RSDA

A symbolic_tbl object (class c("symbolic_tbl", "tbl_df", "tbl", "data.frame")) where each interval variable is a complex column (symbolic_interval): Re() gives the minimum and Im() gives the maximum. This is the native format of the RSDA package (Billard & Diday, 2006; Rodriguez, 2024).

MM (Min-Max)

A plain data.frame where each interval variable is represented by two numeric columns named <var>_min and <var>_max. This is a widely used general-purpose representation.

iGAP

A data.frame where each interval variable is stored as a character column with comma-separated values "min,max". This is the format used by the iGAP software (Correia, 2009).

ARRAY

A three-dimensional numeric array of size [n, p, 2]. The first slice [,,1] contains all minima and the second slice [,,2] contains all maxima. Dimnames encode observation labels, variable names, and c("min", "max"). This format is convenient for matrix-based computations.

SODAS

An XML file on disk produced by the SODAS software (Diday & Noirhomme, 2008). In R, SODAS data is referenced by its file path and read via RSDA::SODAS.to.RSDA(). Since SODAS is a file-based format, it cannot be generated from in-memory data.

SDS

An alias for SODAS. Both refer to the same XML-based format.

Value

A named list with six slots:

RSDA

A symbolic_tbl with complex-encoded symbolic_interval columns.

MM

A data.frame with paired _min/_max columns.

iGAP

A data.frame with comma-separated "min,max" character values.

ARRAY

A three-dimensional numeric array of dimension [n, p, 2] where [,,1] stores minima and [,,2] stores maxima.

SODAS

NULL unless the input is a SODAS XML file path, in which case it stores the original path.

SDS

NULL unless the input is a SODAS/SDS XML file path (alias for SODAS).

Author(s)

Han-Ming Wu

References

Billard, L. and Diday, E. (2006). Symbolic Data Analysis: Conceptual Statistics and Data Mining. Wiley.

Rodriguez, O. (2024). RSDA: R to Symbolic Data Analysis. R package, https://CRAN.R-project.org/package=RSDA.

Correia, M. (2009). Interval GARCH and Aggregation of Predictions.

Diday, E. and Noirhomme-Fraiture, M. (2008). Symbolic Data Analysis and the SODAS Software. Wiley.

See Also

int_detect_format, int_convert_format, int_list_conversions

Examples

data(car.int)
result <- to_all_interval_formats(car.int)
names(result)

# RSDA format (symbolic_tbl)
result$RSDA

# MM format (data.frame with _min/_max columns)
head(result$MM)

# iGAP format (data.frame with comma-separated values)
head(result$iGAP)

# ARRAY format (3D array)
dim(result$ARRAY)
result$ARRAY[1:3, , 1]  # minima
result$ARRAY[1:3, , 2]  # maxima

# SODAS/SDS slots are NULL (file-based format)
result$SODAS
result$SDS

dataSDA documentation built on June 12, 2026, 9:06 a.m.