Contributions: Tolstokoraya Darya: Describtion of the topic, literature review, introductions, comments

Baturina Elina: 2 variables + boxplot

Sorokina Darya: 2 variables + scatterplot

Suetina Anna: 2 variables + barplot

General Infromation about our research

Describtion of the topic We chose Switzerland as a country for our analysis.

Topic: “Digital contacts within family and workplace and its relation to subjective well-being and social exclusion”

Research question: How digital contacts within family and workplace are related to subjective well-being and social exclusion?

Some background and justification of research interest:

Why Switzerland as a country? - Switzerland is one of the wealthiest countries in the world with $92,463 GDP per Capita (Richest Countries in the world 2024., n.d.). This point is directly connected with people’s work, how their work is organized and with people’s happiness and whether they enjoy their lives, as they probably have really high quality conditions of living in such a wealthy country. We got interested in this fact and thought we might derive interesting data in the ESS portal about Switzerland, happiness level there, work and family related data. We wanted to dive deeper and observe what factors are related to the happiness level of the population of Switzerland. SOURCE:Richest Countries in the world 2024. (n.d.).

Literature review

  1. In the study on “Technological affluence and subjective well-being” (Kavetsos, G., & Koutroumpis, P., 2011) a recent European pooled cross-sectional dataset is used, and researchers focus only on access to the internet and ownership of electronic gadgets and its relation to subjective well-being. In our case we want to go further and observe how connections via the Internet between family members and coworkers/bosses are related to a person’s subjective well-being. “Following Scanlon (1993) we study whether an individual’s well-being is enhanced due to the ownership of such technological amenities (TV, mobile phones, which in this setting can be viewed as substantive goods.” They used data only about the possession of electronic technologies: “These surveys ask individuals whether they own a television (TV), digital video disk player (DVD), compact disk music player (CD), computer (PC), internet connection, fixed telephone line and private mobile phone.”
    While in our research we will look at the communication patterns, not just ownership. Also, from their country sample we can conclude that for Switzerland there was no such analysis. It means that another research gap is detected. “Responses are available for 29 countries, including: Austria, Belgium, Bulgaria, Croatia, Cyprus, Czech Republic, Denmark, Estonia, Finland, France, Germany, Greece, Hungary, Ireland, Italy, Latvia, Lithuania, Luxembourg, Malta, the Netherlands, Poland, Portugal, Romania, Slovakia, Slovenia, Spain, Sweden, Turkey and the United Kingdom.”

SOURCE: Kavetsos, G., & Koutroumpis, P. (2011). Technological affluence and subjective well-being. Journal of Economic Psychology, 32(5), 742–753.

  1. Research “Always Available, Always attached: A relational perspective on the effects of mobile phones and social media on Subjective Well-Being” by Taylor & Bazarova is the closest one to our in terms of what they want to measure: “ We want to address how interpersonal communication across the media ecosystem affects the multidimensional concept of subjective well-being (SWB)” (Taylor, S. H., & Bazarova, N. N., 2021) They focus on digital contacts and the feeling of happiness. However, in this study the focus was only on romantic relationships: “One hundred fourteen romantic couples in long-term relationships were recruited to participate in this study during January to March 2019.” (Taylor, S. H., & Bazarova, N. N., 2021). While we are planning not to narrow down to this limited sample and use data to describe a situation on a national level.

SOURCE: Taylor, S. H., & Bazarova, N. N. (2021). Always Available, Always attached: A relational perspective on the effects of mobile phones and social media on Subjective Well-Being. Journal of Computer-Mediated Communication, 26(4), 187–206.

  1. We may want to look not only on digital connection patterns, but also on real-life social connections and its relation to subjective well-being level. In this study on social capital and subjective well-being (Hommerich, C., & Tiefenbach, T., 2017) the variables that are mentioned in it are the ones that we also want to look at and analyze: “To address this issue, we propose the concept of social affiliation, measuring the feeling of belonging to the social whole, of being a respected and valued member of society.” So, we also have variables such as “Feel like part of your team, how much”, “Take part in social activities compared to others of the same age” - which refer to the feeling of belonging to the social whole. However, this study was held in Japan, while we want to observe Switzerland.

SOURCE: Hommerich, C., & Tiefenbach, T. (2017). Analyzing the relationship between Social capital and Subjective Well-Being: The mediating role of social affiliation. Journal of Happiness Studies, 19(4), 1091–1114. https://doi.org/10.1007/s10902-017-9859-9

Description of variables and graphs

General settings

Loading of the packages:

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
library(ggplot2)
library(readr)
library (kableExtra)
## 
## Attaching package: 'kableExtra'
## The following object is masked from 'package:dplyr':
## 
##     group_rows
Mode = function(x){ 
 ta = table(x)
 tam = max(ta)
 if (all(ta == tam))
 mod = NA
 else
 if(is.numeric(x))
 mod = as.numeric(names(ta)[ta == tam])
 else
 mod = names(ta)[ta == tam]
 return(mod)
 }

Downloading the data from ESS round 10

ESS <- read_csv(file = '/Users/admin/Downloads/ESS10/ESS10.csv')
## Rows: 37611 Columns: 618
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## chr    (9): name, proddate, cntry, cntbrthd, lnghom1, lnghom2, fbrncntc, mbr...
## dbl  (594): essround, edition, idno, dweight, pspwght, pweight, anweight, pr...
## dttm  (15): inwds, ainws, ainwe, binwe, cinwe, dinwe, finwe, ginwe, hinwe, i...
## 
## ℹ 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.

Selecting the country & needed variables from dataset

ESS10 <- ESS %>% 
  filter(cntry == "CH") %>% 
  select(idno, acchome, sclact, closepnt, teamfeel, happy, ttminpnt)

ESS10_1 <- ESS %>% 
  filter(cntry == "CH") %>% 
  select(idno, acchome, sclact, closepnt, teamfeel, happy, ttminpnt)

Nominal variable: “acchome”

This variables represent the ability of the respondent to access the internet from home

#R represens this variable as numeric, so we assigning factor variable type
ESS10$acchome <- factor(ESS10$acchome, labels = c("Don't have an access", "Have an access"), ordered= F)

class(ESS10$acchome)
## [1] "factor"
summary(ESS10$acchome)
## Don't have an access       Have an access 
##                  104                 1419

Plot 1: How many people have access to the internet at home?

ggplot() +
  geom_bar(data = ESS10, aes(x = acchome), fill="#00FFFF", col="#0000FF", alpha = 0.5) +
  xlab("Having an ability to access the internet: Home") + 
  ylab("Number of people") +
  ggtitle("The level of people`s access to the Internet at home")

Conclusion 1: 1) In Switzerland there are much more people who have an access to the internet at home in comparison to those who don’t have.

Ordinal variable 1: “sclact”

This variable represents answers of respondents to the question “Compared to other people of your age, how often would you say you take part in social activities?”.

ESS10_sclact <- ESS10_1 %>% 
  filter(sclact != 8 & sclact != 7)

#Deleting observations, which are not needed for the analysis: Refusal* & Don't know*
ESS10$sclact[ESS10$sclact == 8 | ESS10$sclact == 7] <- NA

#R represents this variable as numeric, so we assigning ordered factor variable type
ESS10$sclact <- factor(ESS10$sclact, labels = c("Much less than most", "Less than most", "About the same", "More than most", "Much more than most"), ordered= T)

class(ESS10$sclact)
## [1] "ordered" "factor"
summary(ESS10$sclact)
## Much less than most      Less than most      About the same      More than most 
##                 116                 455                 691                 206 
## Much more than most                NA's 
##                  31                  24

Plot 2: How often do people participate in social activities (compared to others of same age)?

ESS10 = ESS10 %>%
  filter(sclact != 8 )%>%
  filter(sclact != 9 )%>% 
  filter(sclact != 7 )

ESS10$sclact <- factor(ESS10$sclact, labels = c("Much less than most", "Less than most", "About the same", "More than most", "Much more than most"), ordered= F)

ggplot(ESS10 %>% 
         filter(sclact != "NA")) +
  geom_bar(aes(x = sclact), fill="#99FF66", col="#990033", alpha = 0.5) +
  xlab("Frequency of participation in social activities") + 
  ylab("Number of people") +
  ggtitle("The degree of participation in social activities (compared to others of same age)")

Conclusion 2: People in Switzerland think that they are take part in social activities in the same level as others of their age. Fewer people tend to think they participate less than others.

Ordinal variable 2: “closepnt”

This variable represents answers of respondents to the question “Taking everything into consideration, how close do you feel to him/her?”.

ESS10_closepnt <- ESS10_1 %>% 
  select(idno, closepnt) %>% 
  filter(closepnt < 6)

#Deleting observations, which are not needed for the analysis: Not applicable* & Refusal* & Don't know*
ESS10$closepnt[ESS10$closepnt == 6 | ESS10$closepnt == 7 | ESS10$closepnt == 8 | ESS10$closepnt == 9] <- NA

#R represents this variable as numeric, so we assigning ordered factor variable type
ESS10$closepnt <- factor(ESS10$closepnt, labels = c("Extremely close", "Very close", "Quite close", "Not very close", "Not at all close"), ordered= T)

class(ESS10$closepnt)
## [1] "ordered" "factor"
summary(ESS10$closepnt)
##  Extremely close       Very close      Quite close   Not very close 
##              209              432              237               67 
## Not at all close             NA's 
##               23              531

Plot 3: How are people close to their parents?

ggplot(ESS10 %>% 
         filter(closepnt != "NA")) +
  geom_bar(aes(x = closepnt), fill="#CCCCFF", col="#FF7F50", alpha = 0.5) +
  xlab("How close to parents") + 
  ylab("Number of people") +
  ggtitle("The degree of closeness to parents")

Conclusion 3: We see that people in Switzerland are more inclined to be close to their parents.

Interval variable 1: “teamfeel”

This variable represents answers of respondents to the question “If you work in a team, how much do you feel like part of your team?”

ESS10_teamfeel <- ESS10 %>%
  select(teamfeel) %>%
  filter(teamfeel <= 10)

class(ESS10_teamfeel$teamfeel)
## [1] "numeric"
summary(ESS10_teamfeel$teamfeel)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   0.000   8.000   9.000   8.487  10.000  10.000

Plot 4: Do people in Switzerland feel part of their working team?

ggplot(ESS10_teamfeel)+
  geom_histogram( aes(x = teamfeel), binwidth = 1, fill="#367588", col="#6a5acd", alpha = 0.5) +
  xlim(c(0, 10))+
  xlab("How much people feel like a part of their working team") + 
  ylab("Number of people") +
  scale_x_continuous(breaks= seq(0, 10, by=2))+
  geom_vline(aes(xintercept = mean(teamfeel), color = 'mean'), linetype="solid", linewidth = 1) +
  geom_vline(aes(xintercept = median(teamfeel), color = 'median'), linetype="solid", linewidth = 1)+
  geom_vline(aes(xintercept = Mode(teamfeel), color = 'mode'), linetype="solid", linewidth = 1) +
  scale_color_manual(name = "Measurement", values = c(median = "#1e90ff", mean = "#ffb6c1", mode = "#C9F76F"))+
  ggtitle("The level of feeling like a part of working team") 
## Scale for x is already present.
## Adding another scale for x, which will replace the existing scale.

Conclusion 4: As it can be seen from the graph, people in Switzerland mostly feel like a part of their working team as the histogram is right-skewed. Moreover, all central tendency measurement are higher then 8, which represents high lefel of feeling like a part of a workig team.

Interval variable 2: “happy”

This variable represents answers of respondents to the question “Taking all things together, how happy would you say you are?”

ESS10_happy <- ESS10 %>%
  select(happy) %>%
  filter(happy <= 10)

class(ESS10_happy$happy)
## [1] "numeric"
summary(ESS10_happy$happy)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   0.000   8.000   8.000   8.087   9.000  10.000

Plot 5: Do people in Switzerland feel happy?

ggplot(ESS10_happy)+
  geom_histogram( aes(x = happy), binwidth = 1, fill="#367588", col="#6a5acd", alpha = 0.5) +
  xlim(c(0, 10))+
  xlab("How much people feel happy") + 
  ylab("Number of people") +
   scale_x_continuous(breaks= seq(0, 10, by=2))+
  geom_vline(aes(xintercept = mean(happy), color = 'mean'), linetype="solid",linewidth = 1) +
  geom_vline(aes(xintercept = median(happy), color = 'median'), linetype="solid", linewidth = 1)+
  geom_vline(aes(xintercept = Mode(happy), color = 'mode'), linetype="solid",linewidth = 1) +
  scale_color_manual(name = "Measurement", values = c(median = "#1e90ff", mean = "#ffb6c1", mode = "#C9F76F"))+
  ggtitle("Happines in Switzerland")
## Scale for x is already present.
## Adding another scale for x, which will replace the existing scale.

Conclusion 5: The graph illustrates that, on average, people in Switzerkand feel happy as the histogram is right-skewed and mean, median and mode are located approximately in 8 point, which is much higher than the central point (5).

Ratio variable: “ttminpnt”

This variable represents answers of respondents to the question “About how long would it take you to get to where your parents live, on average? Think of the way you would travel and of the time it would take door to door.”

ESS10_ttminpnt <- ESS10 %>%
  select(idno, ttminpnt) %>% 
  filter(ttminpnt != 6666) %>% 
  filter (ttminpnt != 7777) %>% 
  filter(ttminpnt != 8888) %>% 
  filter (ttminpnt != 9999)

class(ESS10_ttminpnt$ttminpnt)
## [1] "numeric"
summary(ESS10_ttminpnt$ttminpnt)
##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##     0.0    10.0    30.0   179.6   180.0  4320.0

Plot 6: How long does it takes for people to get to their parents?

ggplot(ESS10_ttminpnt)+
  geom_histogram(aes(x = ttminpnt), fill="gray", col="#FF6347", alpha = 0.5) +
  xlab("How long does it takes to get to parents, min") + 
  ylab("Number of people") +
  geom_vline(aes(xintercept = mean(ttminpnt), color = 'mean'), linetype="solid",linewidth = 1) +
  geom_vline(aes(xintercept = median(ttminpnt), color = 'median'), linetype="solid", linewidth = 1)+
  geom_vline(aes(xintercept = Mode(ttminpnt), color = 'mode'), linetype="solid",linewidth = 1) +
  scale_color_manual(name = "Measurement", values = c(median = "#1e90ff", mean = "#ffb6c1", mode = "#C9F76F"))+
  ggtitle("Time to parents")+
  xlim(0, 1500)+
  ylim(0, 175)
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
## Warning: Removed 3 rows containing non-finite values (`stat_bin()`).
## Warning: Removed 2 rows containing missing values (`geom_bar()`).

Conclusion 6: On average, it takes 3 hours for people in Switzerland to get to their parents.

Summary of descriptive statistics

v.acchome <- c(NA, Mode(ESS10_1$acchome), NA)
names(v.acchome) <- c("mean", "mode", "median")

v.sclact <- c(NA, Mode(ESS10_sclact$sclact), median(ESS10_sclact$sclact))
names(v.sclact) <- c("mean", "mode", "median")

v.closepnt <- c(NA, Mode(ESS10_closepnt$closepnt), median(ESS10_closepnt$closepnt))
names(v.closepnt) <- c("mean", "mode", "median")

ESS10_teamfeel$teamfeel =  as.numeric(as.character(ESS10_teamfeel$teamfeel))
v.teamfeel <- c(mean(ESS10_teamfeel$teamfeel), Mode(ESS10_teamfeel$teamfeel), median(ESS10_teamfeel$teamfeel))
names(v.teamfeel) <- c("mean", "mode", "median")

ESS10_happy$happy =  as.numeric(as.character(ESS10_happy$happy))
v.happy <- c(mean(ESS10_happy$happy), Mode(ESS10_happy$happy), median(ESS10_happy$happy))
names(v.happy) <- c("mean", "mode", "median")

v.ttminpnt <- c(mean(ESS10_ttminpnt$ttminpnt), Mode(ESS10_ttminpnt$ttminpnt), median(ESS10_ttminpnt$ttminpnt))
names(v.ttminpnt) <- c("mean", "mode", "median")

tendencymeasures =  data.frame(v.acchome, v.sclact, v.closepnt, v.teamfeel, v.happy, v.ttminpnt, stringsAsFactors = FALSE)
kable(tendencymeasures) %>%    
  kable_styling(bootstrap_options=c("bordered", "responsive","striped"), full_width = FALSE)
v.acchome v.sclact v.closepnt v.teamfeel v.happy v.ttminpnt
mean NA NA NA 8.486766 8.086725 179.5907
mode 1 3 2 10.000000 8.000000 10.0000
median NA 3 2 9.000000 8.000000 30.0000

Scatterplot

Do people who feel like part of their working team feel happier than those who do not feel like part of their team?

ggplot(ESS10 %>%
         filter(happy <=10 & teamfeel <= 10 ), aes(x = teamfeel, y = happy)) +
  geom_point( )+
  ylab("How happy are you") +
  xlab("How much you feel like a team") +
  ggtitle("Feeling happy due to feeling like a part of a working team") +
   scale_x_continuous(breaks= seq(0, 10, by=2))+
   scale_y_continuous(breaks= seq(0, 10, by=2))+
  theme_minimal()+
  geom_count()

Answer: Looking at the graph, it can be seen that there is a slight connecting between feeling of belonging to the working team and happiness as quite many high points of each scales corresponds with high values and have bigger size (therefore, there is bigger number of occurrences), however, still there are cases where high values of happiness corresponds with low values of feeling a part of a team and vise versa.

Boxplot

Is there a relation between how close a parent and child live and the closeness of their relationship (assessed by the child)?

ESS_boxplot <- full_join(ESS10_ttminpnt, ESS10_closepnt, by = "idno")

ggplot(ESS10 %>% 
         filter(closepnt != "NA") %>% 
         filter(ttminpnt != 6666) %>% 
         filter (ttminpnt != 7777) %>% 
         filter(ttminpnt != 8888) %>% 
         filter (ttminpnt != 9999), aes(x=closepnt, y=ttminpnt))+
  geom_boxplot(aes(fill = closepnt))+
  stat_summary(fun.y = mean, geom = "point", size = 2, col = "orange")+
  ylim(0, 500)
## Warning: The `fun.y` argument of `stat_summary()` is deprecated as of ggplot2 3.3.0.
## ℹ Please use the `fun` argument instead.
## This warning is displayed once every 8 hours.
## Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
## generated.
## Warning: Removed 89 rows containing non-finite values (`stat_boxplot()`).
## Warning: Removed 89 rows containing non-finite values (`stat_summary()`).

Answer: We see that the average distance to parents increases with decreasing degree of relationship closeness. Therefore we can conclude that families who live in a longer distance from each other have less clode relationships.

Stacked barplot

Are people who have access to the internet at home more involved in social activities (compared to others of the same age)?

ggplot(ESS10 %>% 
         filter(sclact != "NA"), aes(x = sclact, fill = acchome)) +
  geom_bar(position="fill")+
  coord_flip()+
  xlab("Share of population") + 
  ylab("Нaving an ability to access the internet: Home") +
  ggtitle("Participation in social activities due to access to the Internet")

Answer: Looking at the graph, we can see that in Switzerland a fairly large number (about 80%) of people who have internet access at home think that they participate in social activities much less than others their age. Also a large number of people (about 90%) who have internet access at home think that they participate in social activities much more than others.