Learn R Programming

kstIO (version 0.4-0)

write_surmiserelation: Write a (surmise) relation file

Description

Write a surmise relation to a file. The file formats are described in the kstIO-package information page.

Usage

write_surmiserelation(x, filename, format = "SRBT")

Arguments

x

The data to be written, either a quadratic binary matrix or an object of relation class.

filename

A character string specifying the name of the base file.

format

Specification of the files format. Can be "SRBT" (default), "CSV", or "matrix".

Author

Cord Hockemeyer cord.hockemeyer@uni-graz.at

Details

The format values "SRBT" and "matrix" refer to the different generations of file formats described in kstIO-package.

References

Hockemeyer, C. (2001). KST Tools User Manual (2nd ed.). https://kst.hockemeyer.at/techreports/KST-Tools_TechRep_FWF01.pdf.

Poetzi, S. & Wesiak, G. (2001). SRbT Tools User Manual. https://kst.hockemeyer.at/techreports/SRBT-Tools_TechRep_FWF01.pdf

See Also

kstIO-package

Examples

Run this code
# Obtain data to write from the 'pks' package
library(kst)
library(pks)
d <- getwd()
setwd(tempdir())
data(DoignonFalmagne7)
r <- as.relation(kspace(kstructure(as.pattern(DoignonFalmagne7$K, as.set=TRUE))))
# Write surmise relation to file
write_surmiserelation(r, "DF7.bas") # Write in (default) SRBT format
write_surmiserelation(r, "DF7.bas", "matrix") # matrix format
setwd(d)

Run the code above in your browser using DataLab