Setting up my environment

Notes: setting up my R environment by loading the ‘tidyverse’, ‘ggplot2’ and other needed packages

library(tidyverse)
## Warning: package 'ggplot2' was built under R version 4.3.2
## Warning: package 'dplyr' was built under R version 4.3.2
## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
## ✔ dplyr     1.1.3     ✔ readr     2.1.4
## ✔ forcats   1.0.0     ✔ stringr   1.5.0
## ✔ ggplot2   3.4.4     ✔ tibble    3.2.1
## ✔ lubridate 1.9.3     ✔ tidyr     1.3.0
## ✔ purrr     1.0.2     
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag()    masks stats::lag()
## ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
library(ggplot2)

Loading and Viewing my data

Notes: loading and viewing the traceability data set

traceability<- read.csv("scopus.csv")
View(traceability)

Plotting and Visualization of my data

Notes: plotting my traceability data using geom_point and geom_bar function and visualising the data using the ggplot function.

ggplot(data = traceability)+
  geom_bar(mapping = aes(x=Year, fill=Document.Type))+labs(title = "Year of Publication Vs Citation",subtitle = "A graph of traceability articles published over the years against their subsequent citations categorised according to the document type", caption = "Data extrated and analysed by Ing Miracle Lassey")+
  facet_wrap(~Document.Type)+
  theme(axis.text.x = element_text(angle = 45, hjust = 1))

ggplot(data = traceability)+
  geom_point(mapping = aes(x=Year,y=Cited.by, color= Document.Type))