char2file: writes a character onto a file

Description Usage Arguments Value Examples

View source: R/f0.rbsb1.code.r

Description

The reverse operation of file2char. This function is not very tricky, it was written for the completeness.

Usage

1
char2file(chara, file, path="./", ap=FALSE)

Arguments

chara

The character to be written into file.

file

file to be written. According to ap when already exist, it will be destroyed and recreated or completed. When the file is rbsb.cha0, no file is considered but the corresonding character is returned.

path

Directory containing the file.

ap

Must the file be appended if it already exist?

Value

Nothing but a file is created or modified when everything is right -or- according to the value of file, a character is returned.

Examples

1
2
3
4
 rbsb3k("reset");
 char2file(letters, "toto.txt");
 unlink("toto.txt");
 char2file(letters, rbsb.cha0);

rbsb documentation built on May 31, 2017, 1:45 a.m.