Error Message with no reason

install.packages("tidyverse")
install.packages("palmerpenguins")
install.packages("ggplot2")

library(tidyverse)
library(ggplot2)
library(palmerpenguins)

head (palmerpenguins)
Error in head(palmerpenguins) : object 'palmerpenguins' not found

I think you mean

library(palmerpenguins)
head(penguins)

The dataset in palmerpenguins is called penguins, not palmerpenguins. Just switch the name and you are good to go.