write_kdata {kstIO}R Documentation

Write a knowledge space theory file

Description

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

Usage

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

Arguments

x

The data to be written, as a binary matrix.

filename

A character string specifying the name of the data file.

format

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

Details

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

Author(s)

Cord Hockemeyer cord.hockemeyer@uni-graz.at

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

# Obtain data to write from the 'pks' package
d <- getwd()
setwd(tempdir())
data(DoignonFalmagne7)
df <- as.binmat(DoignonFalmagne7$N.R)
# Write data to file
write_kdata(df, "DF7.dat") # Write in (default) SRBT format
write_kdata(DoignonFalmagne7$K, "DF7.dat", "matrix") # matrix format (without any headers)
setwd(d)

[Package kstIO version 0.4-0 Index]