metric_conversion: Formatting feet-inches lengths as meters

Description Usage Arguments Value Examples

View source: R/metric_conversion.R

Description

Takes a character string (or list) representing a length in feet-inches format (e.g. "12-07.45") and converts it to a distance in meters ("3.85m").

Usage

1

Arguments

x

A character vector of distance(s) in feet-inches format (e.g. "12-07.45"), to be converted to meters ("3.85m")

Value

returns the value of the string x which represents a distance in meters, as a character, with unit "m" included

Examples

1
2
3
4
distances <- c("1.23m", "5-02.34", "43.45", "6.89", NA)
metric_conversion(distances)
math_format(metric_conversion(distances))
metric_conversion("5.45m")

JumpeR documentation built on Nov. 17, 2021, 1:07 a.m.