Import data

# excel file
data <- read_excel("data/myData.xlsx")
data
## # A tibble: 224 × 7
##    observed_month prod_type     prod_process   n_hens n_eggs source Eggs_Per_Hen
##    <chr>          <chr>         <chr>           <dbl>  <dbl> <chr>         <dbl>
##  1 42582          hatching eggs all          57975000 1.15e9 ChicE…         19.8
##  2 42613          hatching eggs all          57595000 1.14e9 ChicE…         19.8
##  3 42643          hatching eggs all          57161000 1.09e9 ChicE…         19.1
##  4 42674          hatching eggs all          56857000 1.13e9 ChicE…         19.8
##  5 42704          hatching eggs all          57116000 1.10e9 ChicE…         19.2
##  6 42735          hatching eggs all          57750000 1.13e9 ChicE…         19.6
##  7 42766          hatching eggs all          57991000 1.12e9 ChicE…         19.4
##  8 42794          hatching eggs all          58286000 1.01e9 ChicE…         17.4
##  9 42825          hatching eggs all          58735000 1.13e9 ChicE…         19.2
## 10 42855          hatching eggs all          59072000 1.10e9 ChicE…         18.6
## # ℹ 214 more rows

Plot data

data %>%
    
    ggplot(aes(prod_type)) +
    geom_bar()