#' Retrieves metadata from a Landsat *_MTL.txt file
#'
#' @description
#' Reads metadata from Landsat-8, -9 (more soon) and outputs to an object
#'
#' @param file Path (character vector) to Landsat ..MTL.txt file
#' @return Object of class MetaData_LS
#' @export
#'
get_landsat_mtl <- function(file) {
#
if (!file.exists(file)) {
stop("File not found...")
}
if (!grep(pattern = "MTL.txt", x = file)) {
stop("File is not a _MTL.txt metadata file")
}
data <- readr::read_lines(file)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.