leading.zeros.to.fit: Add zeros in string representing a number

View source: R/clanToolsFunctions.R

leading.zeros.to.fitR Documentation

Add zeros in string representing a number

Description

Add zeros when numbers occur in filenames and such 009 comes before 111 (cf. 9 vs. 111). The number of leading zeros is camculated automatically.

Usage

leading.zeros.to.fit(c(9,111))

Arguments

x

is a vector of numeric values

Value

The vecor of characters wher zeors have been added as necessary

Author(s)

Claus E. Andersen


claus-e-andersen/clanTools documentation built on Nov. 30, 2024, 11:06 p.m.