library(ggplot2)
This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see http://rmarkdown.rstudio.com.
When you click the Knit button a document will be generated that includes both content as well as the output of any embedded R code chunks within the document. You can embed an R code chunk like this:
retail_sales_dataset <- read.csv("retail_sales_dataset.csv")
head(retail_sales_dataset)
## Transaction.ID Date Customer.ID Gender Age Product.Category Quantity
## 1 1 2023-11-24 CUST001 Male 34 Beauty 3
## 2 2 2023-02-27 CUST002 Female 26 Clothing 2
## 3 3 2023-01-13 CUST003 Male 50 Electronics 1
## 4 4 2023-05-21 CUST004 Male 37 Clothing 1
## 5 5 2023-05-06 CUST005 Male 30 Beauty 2
## 6 6 2023-04-25 CUST006 Female 45 Beauty 1
## Price.per.Unit Total.Amount
## 1 50 150
## 2 500 1000
## 3 30 30
## 4 500 500
## 5 50 100
## 6 30 30
summary(retail_sales_dataset)
## Transaction.ID Date Customer.ID Gender
## Min. : 1.0 Length :1000 Length :1000 Length :1000
## 1st Qu.: 250.8 N.unique : 345 N.unique :1000 N.unique : 2
## Median : 500.5 N.blank : 0 N.blank : 0 N.blank : 0
## Mean : 500.5 Min.nchar: 10 Min.nchar: 7 Min.nchar: 4
## 3rd Qu.: 750.2 Max.nchar: 10 Max.nchar: 8 Max.nchar: 6
## Max. :1000.0
## Age Product.Category Quantity Price.per.Unit
## Min. :18.00 Length :1000 Min. :1.000 Min. : 25.0
## 1st Qu.:29.00 N.unique : 3 1st Qu.:1.000 1st Qu.: 30.0
## Median :42.00 N.blank : 0 Median :3.000 Median : 50.0
## Mean :41.39 Min.nchar: 6 Mean :2.514 Mean :179.9
## 3rd Qu.:53.00 Max.nchar: 11 3rd Qu.:4.000 3rd Qu.:300.0
## Max. :64.00 Max. :4.000 Max. :500.0
## Total.Amount
## Min. : 25
## 1st Qu.: 60
## Median : 135
## Mean : 456
## 3rd Qu.: 900
## Max. :2000
You can also embed plots, for example:
## `geom_smooth()` using method = 'loess' and formula = 'y ~ x'
Note that the echo = FALSE parameter was added to the
code chunk to prevent printing of the R code that generated the
plot.