Description Usage Arguments Value Examples
View source: R/parse_version.R
Parse a character vector to semantic versions
1 |
version |
A character vector |
A list of "svptr" objects. The list itself is of class "svlist"
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | semver <- parse_version(c("1.2.3", "1.2.4", "1.0.0", "1.2.4-beta", "2.1.3-alpha", "1.9.4"))
max(semver)
ver124a <- semver[semver > "1.2.4-alpha"]
sort(ver124a)
# compare versions
semver[[1]] < semver[[2]]
# compare against a version
semver > semver[1]
# compare against a character string
semver > "1.7.2"
# sort versions
sort(semver)
order(semver)
rank(semver)
# get summary statistics
min(semver)
max(semver)
range(semver)
# coerce versions
as.character(semver)
as.data.frame(semver)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.