Description Usage Arguments Value Examples
View source: R/valid_check_digit.R
Calculates the VIN check digit and compares it to VIN position 9. For US-based VINs, this determines if the VIN is valid. This may not apply to VINs from outside of the United States.
1 | valid_check_digit(vin, value = FALSE, guess = FALSE)
|
vin |
character. The VIN to check. VINs must be compete, i.e. 17 digits with no wildcards. |
value |
logical. Should the calculated check digit be returned instead? |
guess |
logical. Should incorrect characters be replaced by the best guess at corrected characters? O -> 0 I -> 1 Q -> 0 |
If value
is FALSE
, a logical value is returned.
If value
is TRUE
, a character is returned.
1 2 3 | valid_check_digit("WDBEA30D3HA391172") # True
valid_check_digit("WDBEA30D3HA391172", value = TRUE)
valid_check_digit("WDBEA3QD3HA39I172", guess = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.