format_string {SparkR}R Documentation

format_string

Description

Formats the arguments in printf-style and returns the result as a string column.

Usage

format_string(format, x, ...)

## S4 method for signature 'character,Column'
format_string(format, x, ...)

Arguments

format

a character object of format strings.

x

a Column.

...

additional Column(s).

Note

format_string since 1.5.0

See Also

Other string_funcs: ascii, base64, concat_ws, concat, decode, encode, format_number, initcap, instr, length, levenshtein, locate, lower, lpad, ltrim, regexp_extract, regexp_replace, reverse, rpad, rtrim, soundex, substring_index, translate, trim, unbase64, upper

Examples

## Not run: format_string('%d %s', df$a, df$b)

[Package SparkR version 2.2.2 Index]