Skip to contents

Checks whether a ticker symbol adheres to the format "BTC-USDT", consisting of uppercase alphanumeric characters separated by a dash.

Usage

verify_symbol(ticker)

Arguments

ticker

Character string representing the ticker symbol to verify.

Value

Logical; TRUE if the symbol is valid, FALSE otherwise.

Examples

if (FALSE) { # \dontrun{
verify_symbol("BTC-USDT")  # Returns TRUE
verify_symbol("btc-usdt")  # Returns FALSE
verify_symbol("BTC_USDT")  # Returns FALSE
} # }