# Load the dataset
data(nhl_data)
# View the first few rows
head(nhl_data)
# Filter the data for players drafted in a specific year, e.g., 2023
nhl_2023 <- dplyr::filter(nhl_data, year == 2023)
# View the first few rows
head(nhl_2023)
# Filter the data to include only ESPN as the source
nhl_data |>
dplyr::filter(source == "ESPN")
Run the code above in your browser using DataLab