#Flipped Assignment Group - 3 First Step was to read data from given link

data <-  read.csv("https://raw.githubusercontent.com/tmatis12/datafiles/main/normtemp.csv")

##For Resting Heartbeat of Males ### First lets take subset from the main column and perform statistics over it

Males<-data[1:65,3]
Summary_males <- summary(Males)
variance_males <- var(Males)
std_males <- sd(Males)
IQR_males <- IQR (Males)

From following statistics we can see that minimum is Males, maximum is Males , standard deviation is rsd(“Males”)` and Sample mean is NA

Next is to plot Histogram of males

hist_male <- hist(Males,main="histogram of male heartbeat",col="blue", xlab = "Resting heartbeat")

We can see from above plot that most males resting heartbeat falls in bin of 70-75

Next is to plot Normal probabilty plot of males

Normal_male_plot <- qqnorm(Males,main ="Normal Probability plot for heartbeat of males" , col="blue")

comments - Above given plot is normal probability plot for resting heartbeat for male

##For Resting Heartbeat of Females ### First lets take subset from the main column and perform statistics over it

females<-data[66:130,3]
summary_females <- summary(females)
variance_females <- var(females)
std_females <- sd(females)
IQR_females <- IQR (females)

From following statistics we can see that minimum is females, maximum is females , standard deviation is rsd(“females”)` and Sample mean is NA

Next is to plot Histogram of females

hist_female <-hist(females,main="histogram of female heartbeat",col="pink")

We can see from above plot that most females resting heartbeat falls in bin of 75-80

Next is to plot Normal probabilty plot of females

Normal_female_plot <- qqnorm(females,main ="Normal Probability plot for heartbeat of females" , col="pink")

comments - Above given plot is normal probability plot for resting heartbeat for female

##boxplot

c <- boxplot(Males,females,main ="Resting heart rates for males and females respectively",names = c("Males", "Females"),ylab="Resting Heartbeat")

comments - Above box plot shows median for female is greater than that of males

entire code


data <-  read.csv("https://raw.githubusercontent.com/tmatis12/datafiles/main/normtemp.csv")

## males ------------------------

Males<-data[1:65,3]

#summary
Summary_males <- summary(Males)
summary_male_list <- as.list(Summary_males)
#Descriptive Stats

variance_males <- var(Males)
std_males <- sd(Males)
IQR_males <- IQR (Males)

# Histogram for male 
hist_male <- hist(Males,main="histogram of male heartbeat",col="blue")

#Normal Probility plot
Normal_male_plot <- qqnorm(Males,main ="Normal Probability plot for heartbeat of males" , xlab="x-males",ylab="Heartbeat" , col="blue")


# Females ----------------------

females<-data[66:130,3]

#summary
summary_females <- summary(females)
summary_females_list <- as.list(summary_female)
#Descriptive Stats

variance_females <- var(females)
std_females <- sd(females)
IQR_females <- IQR (females)

# Histogram for female 
hist_female <-hist(females,main="histogram of female heartbeat",col="pink")

#Normal Probility plot
Normal_female_plot <- qqnorm(females,main ="Normal Probability plot for heartbeat of females" , xlab="x-females" ,ylab="Heartbeat" , col="pink")


#-------------------------------------------------------------------------------


c <- boxplot(Males,females,main ="Resting heart rates for males and females respectively",names = c("Males", "Females"),ylab="Resting Heartbeat")