validip {getip} | R Documentation |
validip
Description
Check if a string is a valid IP address. Currently only IPv4 addresses are supported.
Usage
validip(ip)
Arguments
ip |
A string or vector of strings. |
Details
This function is not like a 'ping'. It merely checks if the string is correctly formatted and could theoretically be a valid IP address.
Value
Returns TRUE
if the input is a potentially valid IP address, and
FALSE
otherwise.
Examples
library(getip)
validip(c("192.168.1.1", "700.168.1.1"))
[Package getip version 0.1-4 Index]