library(flexdashboard)
library(readr)
bmi <- read_csv("~/kaggle_data_set/bmi.csv")
## Rows: 741 Columns: 5
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## chr (1): BmiClass
## dbl (4): Age, Height, Weight, Bmi
## 
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
summary(bmi)
##       Age            Height          Weight            Bmi       
##  Min.   :15.00   Min.   :1.460   Min.   : 25.90   Min.   :12.15  
##  1st Qu.:22.00   1st Qu.:1.670   1st Qu.: 63.00   1st Qu.:22.13  
##  Median :29.00   Median :1.721   Median : 72.90   Median :24.13  
##  Mean   :31.62   Mean   :1.709   Mean   : 78.41   Mean   :26.37  
##  3rd Qu.:40.00   3rd Qu.:1.751   3rd Qu.: 83.30   3rd Qu.:27.25  
##  Max.   :61.00   Max.   :2.070   Max.   :270.00   Max.   :66.30  
##    BmiClass        
##  Length:741        
##  Class :character  
##  Mode  :character  
##                    
##                    
## 
library(ggplot2)
library(dplyr)
## 
## Attaching package: 'dplyr'
## 
## The following objects are masked from 'package:stats':
## 
##     filter, lag
## 
## The following objects are masked from 'package:base':
## 
##     intersect, setdiff, setequal, union
plot<-bmi%>%ggplot(aes(bmi$Height,bmi$Weight))+geom_point()+geom_smooth(method = "lm",sd=0)+theme_minimal()
## Warning in geom_smooth(method = "lm", sd = 0): Ignoring unknown parameters:
## `sd`
plot
## `geom_smooth()` using formula = 'y ~ x'

lot<-bmi%>%ggplot(aes(Weight))+geom_histogram(fill='BLUE')+theme_minimal()
lot
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

ot<-bmi%>%ggplot(aes(BmiClass,Weight))+geom_boxplot(color='purple',fill="orange")+theme_minimal()
ot

t<-bmi%>%ggplot(aes(Height,fill=BmiClass))+geom_density()
t