Learn R Programming

stringfish (version 0.19.2)

convert_to_sf_vector: convert_to_sf_vector

Description

Converts a character vector to an `sf_vec`-backed stringfish vector `convert_to_sf()` is a compatibility alias for `convert_to_sf_vector()`.

Usage

convert_to_sf_vector(x, length.out = length(x))

Value

The converted character vector

Arguments

x

A character vector

length.out

Optional output length used to recycle `x`

Details

Converts a character vector to a stringfish vector backed by `sf_vec`. If `length.out` is supplied, `x` is recycled to that length before conversion. The opposite of `materialize`.

Examples

Run this code
x <- convert_to_sf_vector(letters)

Run the code above in your browser using DataLab