Given a character vector 'vec', return a character(1) representing the line of code used to generate 'vec'

vector_as_code(vec)

Arguments

vec

A character vector

Value

A character(1) representing the segment of code constructing vec

Author

Nicholas J. Eagles

Examples


fruits <- c("apple", "banana", "cherry")
message(slurmjobs:::vector_as_code(fruits))
#> c("apple", "banana", "cherry")