# Step 1: Load the necessary library (if not already loaded)
library(dplyr)
# Step 2: Read your dataset into a data frame (replace "your_dataset.csv" with your actual file path)
your_data <- read.csv("your_dataset.csv")
# Step 3: Rename the columns using the rename() function from the dplyr package
your_data <- your_data %>%
rename(
new_column_name1 = old_column_name1,
new_column_name2 = old_column_name2,
# Add more lines if you have additional columns to rename
)
# Step 4: View the updated dataset
print(your_data)