In this project, we will use Facebook sample user data and explore their various features:

##  [1] "userid"                "age"                  
##  [3] "dob_day"               "dob_year"             
##  [5] "dob_month"             "gender"               
##  [7] "tenure"                "friend_count"         
##  [9] "friendships_initiated" "likes"                
## [11] "likes_received"        "mobile_likes"         
## [13] "mobile_likes_received" "www_likes"            
## [15] "www_likes_received"

Explore - Friend Count

Correlation - Friend Count & Friendships Initiated

## 
##  Pearson's product-moment correlation
## 
## data:  friendships_initiated and friend_count
## t = 460.81, df = 99001, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.8238590 0.8278205
## sample estimates:
##     cor 
## 0.82585

Explore - User Birthday

Explore - User Gender

Count - User Gender

## 
## female   male 
##  40254  58574

Summary - User Gender

## facebook$gender: female
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##       0      37      96     242     244    4923 
## -------------------------------------------------------- 
## facebook$gender: male
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##       0      27      74     165     182    4917

Gender Vs. Age

Gender Vs. Friend Count

## facebook$gender: female
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##       0      37      96     242     244    4923 
## -------------------------------------------------------- 
## facebook$gender: male
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##       0      27      74     165     182    4917

Gender Vs. Friendships Initiated

## facebook$gender: female
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##     0.0    19.0    49.0   113.9   124.8  3654.0 
## -------------------------------------------------------- 
## facebook$gender: male
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##     0.0    15.0    44.0   103.1   111.0  4144.0

Gender Vs. Likes

## facebook$gender: female
## [1] 3507665
## -------------------------------------------------------- 
## facebook$gender: male
## [1] 1430175

Explore - Tenure

Summary - Friend Count Per Year

##     Min.  1st Qu.   Median     Mean  3rd Qu.     Max. 
##   0.0000   0.0775   0.2205   0.6096   0.5658 417.0000

Proportion - Friendships Initiated and Tenure

Explore - Age

Age and Friend Count

Correlation - Age and Friend Count

## 
##  Pearson's product-moment correlation
## 
## data:  age and friend_count
## t = -8.6268, df = 99001, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.03363072 -0.02118189
## sample estimates:
##         cor 
## -0.02740737

Correlation - Age < 70 and Friend Count

Pearson Correlation
## 
##  Pearson's product-moment correlation
## 
## data:  age and friend_count
## t = -52.592, df = 91029, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.1780220 -0.1654129
## sample estimates:
##        cor 
## -0.1717245
Spearman Correlation
## 
##  Spearman's rank correlation rho
## 
## data:  age and friend_count
## S = 1.5782e+14, p-value < 2.2e-16
## alternative hypothesis: true rho is not equal to 0
## sample estimates:
##        rho 
## -0.2552934
Kendall Correlation
## 
##  Kendall's rank correlation tau
## 
## data:  age and friend_count
## z = -76.917, p-value < 2.2e-16
## alternative hypothesis: true tau is not equal to 0
## sample estimates:
##        tau 
## -0.1725472

Plots - Age and Friend Count

Age and Friendships Initiated

Explore - Mobile Likes

Summary - Mobile Likes

##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##     0.0     0.0     4.0   106.1    46.0 25111.0

Correlation - Age and Mobile Likes

## 
##  Pearson's product-moment correlation
## 
## data:  age and mobile_likes
## t = -8.4088, df = 99001, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.03293894 -0.02048964
## sample estimates:
##         cor 
## -0.02671533

Explore - Likes Recieved

Correlation - Likes Received and www Likes Received

## 
##  Pearson's product-moment correlation
## 
## data:  facebook$www_likes_received and facebook$likes_received
## t = 937.1, df = 99001, p-value < 2.2e-16
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.9473553 0.9486176
## sample estimates:
##       cor 
## 0.9479902

Correlation - Feature Set