# your R code here
library(readxl)
bwl26 <- read_excel("bwl26.xlsx")
# View first few rows
head(bwl26)
## # A tibble: 6 × 6
## Latitude Longitude `Date of collection` `Location/Notes` Initial Sample
## <dbl> <dbl> <dttm> <chr> <chr> <dbl>
## 1 31.4 -110. 2026-01-23 00:00:00 GPS#3 nj 1
## 2 31.4 -110. NA GPS#3 nj 2
## 3 31.5 -110. 2024-11-16 00:00:00 Group #2 MM 3
## 4 31.4 -110. NA 5 Feet Away, Site #3 OJ 4
## 5 31.5 -110. 2024-03-02 00:00:00 CSHIPEK MM 5
## 6 31.4 -110. NA <NA> nj 6
library(leaflet)
library(readxl)
library(dplyr)
##
## Attaching package: 'dplyr'
## The following objects are masked from 'package:stats':
##
## filter, lag
## The following objects are masked from 'package:base':
##
## intersect, setdiff, setequal, union
# Read Excel data
data <- bwl26
# Inspect expected columns
head(data)
## # A tibble: 6 × 6
## Latitude Longitude `Date of collection` `Location/Notes` Initial Sample
## <dbl> <dbl> <dttm> <chr> <chr> <dbl>
## 1 31.4 -110. 2026-01-23 00:00:00 GPS#3 nj 1
## 2 31.4 -110. NA GPS#3 nj 2
## 3 31.5 -110. 2024-11-16 00:00:00 Group #2 MM 3
## 4 31.4 -110. NA 5 Feet Away, Site #3 OJ 4
## 5 31.5 -110. 2024-03-02 00:00:00 CSHIPEK MM 5
## 6 31.4 -110. NA <NA> nj 6
leaflet(data) %>%
# 1. Base Satellite Layer
addProviderTiles(providers$Esri.WorldImagery) %>%
# 2. Overlay Layer (Streets and Labels)
addProviderTiles(providers$Stadia.StamenTerrainLabels) %>%
addCircleMarkers(
lng = ~Longitude,
lat = ~Latitude,
radius = 4,
color = "lightblue",
fillOpacity = 0.8,
popup = ~as.character(Sample),
options = pathOptions(clickable=TRUE)
) %>%
addScaleBar(position = "bottomleft")