library(readr)
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
# Load the CSV file
NLB_data <- read.csv("nlb_data.csv", sep = ";")

# Remove columns 2 to 8
NLB_data <- NLB_data %>% select(-c(2:8, 101:116))

# Display the first few rows of the modified dataset
head(NLB_data)
##   status                  Q1      Q3a
## 1 Status Koliko ste stari?   Gotovina
## 2      6                   7        3
## 3      6                   9        2
## 4      6                   9        2
## 5      6                   7        3
## 6      6                   7        2
##                                                                Q3b
## 1 Plačilo z debetno ali kreditno kartico (uporaba fizične kartice)
## 2                                                                2
## 3                                                                5
## 4                                                                4
## 5                                                                5
## 6                                                                5
##                   Q3c                       Q3d           Q4a               Q4b
## 1 Plačilo s telefonom Drugo (PayPal, Stripe,..) Nakupi do 10€ Nakupi med 11-99€
## 2                   5                         2             4                 3
## 3                   1                         1             2                 1
## 4                   4                         1             2                 2
## 5                   5                         1             2                 2
## 6                   5                         1             2                 1
##                    Q4c              Q4d
## 1 Nakupi med 100-1000€ Nakupi nad 1000€
## 2                    2                1
## 3                    1                1
## 4                    1                1
## 5                    1                1
## 6                    1                1
##                                                                         Q5
## 1 Kako se običajno odzovete, če prodajalec ne sprejema digitalnih plačil? 
## 2                                                                        2
## 3                                                                        1
## 4                                                                        2
## 5                                                                        1
## 6                                                                        1
##                  Q5_4_text                                     Q6a
## 1 Drugo (prosim navedite): Plača ali zaslužek iz študentskega dela
## 2                       -2                                       3
## 3                       -2                                       4
## 4                       -2                                       3
## 5                       -2                                       3
## 6                       -2                                       4
##                              Q6b                                       Q6c
## 1 Žepnina (od družinskih članov) Darila (ob rojstnih dnevih, praznikih...)
## 2                              2                                         1
## 3                              2                                         1
## 4                              3                                         1
## 5                              3                                         2
## 6                              3                                         3
##                                                                Q6d
## 1 Delo na črno ali priložnostno delo (varstvo otrok, tutorstvo...)
## 2                                                                1
## 3                                                                4
## 4                                                                4
## 5                                                                4
## 6                                                                4
##                              Q6e
## 1 Državne in/ali socialne pomoči
## 2                              3
## 3                              4
## 4                              4
## 5                              4
## 6                              4
##                                                         Q6f
## 1 Državne in druge oblike štipendij (Zoisova, kadrovska...)
## 2                                                         3
## 3                                                         4
## 4                                                         4
## 5                                                         3
## 6                                                         4
##                                                  Q6g
## 1 Donosi iz naložb (delnice, obveznice, kripto itd.)
## 2                                                  3
## 3                                                  3
## 4                                                  2
## 5                                                  4
## 6                                                  4
##                                                                                                                                                                     Q7
## 1 Ali vi varčujete denar? (Vprašanje NE  zajema morebitnih privarčevanih sredstev, ki so jih za vas varčevali oziroma jih varčujejo starši ali drugi družinski člani) 
## 2                                                                                                                                                                    1
## 3                                                                                                                                                                    1
## 4                                                                                                                                                                    1
## 5                                                                                                                                                                    1
## 6                                                                                                                                                                    2
##   Q8a
## 1  NA
## 2   5
## 3   7
## 4   7
## 5   7
## 6  -2
##                                                                                                                                                                       Q9a
## 1 Običajno denar porabim v obliki, v kateri sem ga prejel_a (ne spreminjam oblike prejetega denarja npr. polaganje gotovine na banko ali dvigovanje denarja iz  kartice).
## 2                                                                                                                                                                       6
## 3                                                                                                                                                                       7
## 4                                                                                                                                                                       6
## 5                                                                                                                                                                       6
## 6                                                                                                                                                                       7
##                                                                                                                                                           Q9b
## 1 Zaradi varnosti svojih osebnih podatkov se počutim zaskrbljenega_o, ko uporabljam digitalne načine plačevanja (npr. spletno bančništvo, mobilne denarnice).
## 2                                                                                                                                                           3
## 3                                                                                                                                                           6
## 4                                                                                                                                                           2
## 5                                                                                                                                                           5
## 6                                                                                                                                                           4
##                                                                      Q9c
## 1 Digitalno plačevanje se mi zdi manj varno kakor gotovinsko plačevanje.
## 2                                                                      5
## 3                                                                      3
## 4                                                                      3
## 5                                                                      6
## 6                                                                      7
##                                                                                                                                     Q9d
## 1 Več zaupanja imam v digitalne načine plačevanja, če ponujajo funkcije, kot so dvofaktorska avtentikacija ali biometrična preverjanja.
## 2                                                                                                                                     6
## 3                                                                                                                                     6
## 4                                                                                                                                     6
## 5                                                                                                                                     7
## 6                                                                                                                                     4
##                                            Q9e
## 1 Počutim se varno, ko s seboj nosim gotovino.
## 2                                            4
## 3                                            3
## 4                                            3
## 5                                            4
## 6                                            4
##                                                                          Q9f
## 1 Raje uporabljam digitalna plačila, ker so bolj priročna in prihranijo čas.
## 2                                                                          7
## 3                                                                          7
## 4                                                                          7
## 5                                                                          7
## 6                                                                          7
##                                                                                                                                                        Q9g
## 1 Raje uporabljam gotovino, da bi se izognil_a pretirani porabi, (ob porabljanju gotovine se bolj zavedam svojega zapravljanja in je le-to bolj zavestno).
## 2                                                                                                                                                        6
## 3                                                                                                                                                        1
## 4                                                                                                                                                        1
## 5                                                                                                                                                        1
## 6                                                                                                                                                        4
##                                                                                                                                           Q9h
## 1 Gotovino najpogosteje uporabim tam, kjer digitalna plačila niso mogoča, v nasprotnem primeru pa se raje poslužujem digitalnega plačevanja. 
## 2                                                                                                                                           7
## 3                                                                                                                                           6
## 4                                                                                                                                           7
## 5                                                                                                                                           7
## 6                                                                                                                                           7
##                Q31_2a              Q31_2b                      Q31_2c
## 1 Enostavnost uporabe Hitrost transakcije Možnost uporabe v trgovinah
## 2                   7                   7                           6
## 3                   6                   7                           5
## 4                   7                   6                           6
## 5                   7                   7                           7
## 6                   7                   7                           7
##                        Q31_2d                                        Q31_2e
## 1 Varnost plačilnega sredstva Funkcije za sledenje in načrtovanje proračuna
## 2                           6                                             3
## 3                           7                                             7
## 4                           6                                             4
## 5                           7                                             7
## 6                           7                                             7
##               Q31_2f     Q10a                      Q10b
## 1 Zasebnost uporabe  Gotovina (Fizična) Debetna kartica
## 2                  6        6                         6
## 3                  6        3                         7
## 4                  5        6                         6
## 5                  7        6                         5
## 6                  7        7                         4
##                         Q10c                                        Q10d
## 1 (Fizična) kreditna kartica Plačevanje s telefonom (Flik, Apple pay...)
## 2                          6                                           7
## 3                          7                                           3
## 4                          4                                           6
## 5                          4                                           6
## 6                          4                                           4
##                         Q10e     Q11a                      Q11b
## 1 Neobanke (Revolut, N26...) Gotovina (Fizična) debetna kartica
## 2                          6        5                         6
## 3                          6        7                         7
## 4                          6        4                         7
## 5                          6        3                         6
## 6                          4        7                         7
##                         Q11c                   Q11d                       Q11e
## 1 (Fizična) kreditna kartica Plačevanje s telefonom Neobanke (Revolut, N26...)
## 2                          6                      7                          6
## 3                          7                      6                          6
## 4                          7                      7                          7
## 5                          6                      7                          7
## 6                          7                      7                          7
##       Q12a                      Q12b                       Q12c
## 1 Gotovina (Fizična) debetna kartica (Fizična) kreditna kartica
## 2        6                         7                          7
## 3        6                         6                          6
## 4        7                         7                          7
## 5        6                         7                          7
## 6        7                         7                          7
##                     Q12d                       Q12e     Q13a
## 1 Plačevanje s telefonom Neobanke (Revolut, N26...) Gotovina
## 2                      7                          6        5
## 3                      6                          6        5
## 4                      7                          7        4
## 5                      6                          6        1
## 6                      7                          4        7
##                        Q13b                       Q13c                   Q13d
## 1 (Fizična) debetna kartica (Fizična) kreditna kartica Plačevanje s telefonom
## 2                         6                          6                      7
## 3                         7                          7                      7
## 4                         7                          7                      7
## 5                         6                          6                      7
## 6                         7                          7                      7
##                         Q13e     Q14a                      Q14b
## 1 Neobanke (Revolut, N26...) Gotovina (Fizična) debetna kartica
## 2                          7        7                         6
## 3                          7        7                         1
## 4                          7        6                         5
## 5                          7        7                         4
## 6                          7        4                         7
##                         Q14c                   Q14d                       Q14e
## 1 (Fizična) kreditna kartica Plačevanje s telefonom Neobanke (Revolut, N26...)
## 2                          5                      5                          6
## 3                          1                      1                          1
## 4                          5                      5                          5
## 5                          4                      4                          4
## 6                          7                      7                          7
##       Q15a                      Q15b                       Q15c
## 1 Gotovina (Fizična) debetna kartica (Fizična) kreditna kartica
## 2        7                         5                          5
## 3        2                         7                          4
## 4        5                         7                          7
## 5        6                         5                          1
## 6        4                         7                          7
##                     Q15d                       Q15e
## 1 Plačevanje s telefonom Neobanke (Revolut, N26...)
## 2                      3                          3
## 3                      1                          6
## 4                      7                          7
## 5                      5                          5
## 6                      7                          7
##                                                           Q16a
## 1 Izbiram načine plačevanja, kot jih izbirajo moji prijatelji.
## 2                                                            5
## 3                                                            4
## 4                                                            4
## 5                                                            7
## 6                                                            4
##                                                                Q16b
## 1 Izbiram načine plačevanja, kot jih izbirajo moji družinski člani.
## 2                                                                 2
## 3                                                                 4
## 4                                                                 4
## 5                                                                 7
## 6                                                                 4
##                                                    Q17               Q17_5_text
## 1 Kako si najpogosteje delite stroške med prijatelji?  Drugo (prosim navedite):
## 2                                                    2                       -2
## 3                                                    2                       -2
## 4                                                    2                       -2
## 5                                                    2                       -2
## 6                                                    2                       -2
##                        Q18a                                Q18b
## 1 Lahko nakažem točno vsoto Da se izognem plačevanju z gotovino
## 2                         1                                   0
## 3                         1                                   1
## 4                         1                                   1
## 5                         1                                   1
## 6                         1                                   1
##                              Q18c
## 1 Ker je proces hiter in priročen
## 2                               1
## 3                               1
## 4                               1
## 5                               1
## 6                               1
##                                                                      Q18d
## 1 Ker imam zabeležene svoje transakcije in tako lažje vodim svoje finance
## 2                                                                       0
## 3                                                                       0
## 4                                                                       1
## 5                                                                       1
## 6                                                                       1
##                       Q18e                Q18e_text
## 1 Drugo (prosim navedite): Drugo (prosim navedite):
## 2                        0                       -2
## 3                        0                       -2
## 4                        0                       -2
## 5                        0                       -2
## 6                        0                       -2
##                             Q19a                       Q19b             Q19c
## 1 Goljufije (npr. kraja denarja) Razkritje osebnih podatkov Kraja identitete
## 2                              3                          5                3
## 3                              5                          5                6
## 4                              3                          3                3
## 5                              5                          5                5
## 6                              7                          7                7
##                                      Q19d
## 1 Izguba dostopa zaradi hekerskega napada
## 2                                       3
## 3                                       7
## 4                                       3
## 5                                       6
## 6                                       7
##                                                                     Q20
## 1 Ali ste bili vi (oz. kdo od vaših bližnjih) žrtev spletne goljufije? 
## 2                                                                     2
## 3                                                                     3
## 4                                                                     4
## 5                                                                     4
## 6                                                                     1
##                                                                                      Q21a
## 1 Pogosteje uporabljam gotovino v neznanih ali sumljivih situacijah (npr. med potovanji).
## 2                                                                                       0
## 3                                                                                       0
## 4                                                                                      -2
## 5                                                                                      -2
## 6                                                                                      -1
##                                                                                                                                                                            Q21b
## 1 Pogosteje uporabljam digitalna plačilna sredstva, kot so virtualne ali enkratne kartice, ki jih omogočajo neobanke, v neznanih ali sumljivih situacijah (npr. med potovanji).
## 2                                                                                                                                                                             0
## 3                                                                                                                                                                             0
## 4                                                                                                                                                                            -2
## 5                                                                                                                                                                            -2
## 6                                                                                                                                                                            -1
##                                                   Q21c
## 1 Postal_a sem bolj previden_na pri spletnih plačilih.
## 2                                                    1
## 3                                                    1
## 4                                                   -2
## 5                                                   -2
## 6                                                   -1
##                                                                                       Q21d
## 1 Preklopil_a sem na varnejše plačilne možnosti (npr. mobilne denarnice z avtentikacijo). 
## 2                                                                                        0
## 3                                                                                        0
## 4                                                                                       -2
## 5                                                                                       -2
## 6                                                                                       -1
##                              Q21e
## 1 Moje vedenje se ni spremenilo. 
## 2                               0
## 3                               0
## 4                              -2
## 5                              -2
## 6                              -1
##                                                                       Q22
## 1 Če bi imeli možnost, ali bi popolnoma preklopili na digitalna plačila? 
## 2                                                                       2
## 3                                                                       2
## 4                                                                       2
## 5                                                                       1
## 6                                                                       1
##                    Q23
## 1 Katerega spola ste? 
## 2                    1
## 3                    2
## 4                    2
## 5                    2
## 6                    2
##                                                             Q24
## 1 Katera je vaša najvišja dosežena stopnja dosežene izobrazbe? 
## 2                                                             6
## 3                                                             5
## 4                                                             4
## 5                                                             4
## 6                                                             4
##                               Q25 Q25_5_text
## 1 Kakšen je vaš trenutni status?      Drugo:
## 2                               1         -2
## 3                               1         -2
## 4                               1         -2
## 5                               1         -2
## 6                               1         -2
##                                                          Q26
## 1 Kakšna je višina vaših trenutnih neto mesečnih prihodkov? 
## 2                                                          2
## 3                                                          2
## 4                                                          3
## 5                                                          2
## 6                                                          4
##                                                      Q27
## 1 Katero banko trenutno uporabljate kot primarno banko? 
## 2                                                      2
## 3                                                      2
## 4                                                      7
## 5                                                      1
## 6                                                      1
##                 Q27_7_text
## 1 Drugo (prosim navedite):
## 2                       -2
## 3                       -2
## 4                Unicredit
## 5                       -2
## 6                       -2

Dataset overview

Variables description

Q1a - Age

Q3 - How many times a month do you use the following payment methods on average?

  • Q3a - Cash
  • Q3b - Debit or Credit (physical) cards
  • Q3c - Phone
  • Q3d - Other (PayPal, Stripe..)

Q4 - How often do you use cash payment for the following purchases?

  • Q4a - Purchases up to €10
  • Q4b - Purchases between €11 and €99
  • Q4c - Purchases between €100 and €1000
  • Q4d - Purchases over €1000

Q5 - How do you usually respond if a merchant does not accept digital payments?

  • Q5a - I prefer to go elsewhere and pay with a digital payment method.
  • Q5b - I pay in the form available, even if it means withdrawing cash from an ATM.
  • Q5c - I have not encountered such a situation yet.
  • Q5d - Other (please specify).

Q6 - Which of the following income sources do you have, and how do you receive them?

  • Q6a - Salary or earnings from student work
  • Q6b - Pocket Money (from family members)
  • Q6c - Gifts (for birthdays, holidays, etc.)
  • Q6d - Unreported or occasional work (childcare, tutoring, etc.)
  • Q6e - Government and/or social benefits
  • Q6f - Government and other forms of scholarships (e.g., Zois, corporate)
  • Q6g - Returns from investments (stocks, bonds, cryptocurrencies, etc.)

Q7 - Do you save money? (This question does NOT include savings from parents or family members.)

  • Q7a - Yes
  • Q7b - No

Q8a - In what form do you save money? (Digital vs. cash savings)

Q9 - Various attitudes towards digital and cash payments.

  • Q9a - I usually spend money in the form in which I received it.
  • Q9b - I feel concerned about the security of my personal information when using digital payment methods.
  • Q9c - I find digital payments less secure than cash payments.
  • Q9d - I have more confidence in digital payment methods if they offer features like two-factor authentication.
  • Q9e - I feel safe when I carry cash with me.
  • Q9f - I prefer to use digital payments because they are more convenient and save time.
  • Q9g - I prefer to use cash to avoid overspending.
  • Q9h - I use cash only when digital payments are not possible.

Q10 - How safe do you think the following payment methods are?

  • Q10a - Cash
  • Q10b - (Physical) Debit Card
  • Q10c - (Physical) Credit Card
  • Q10d - Paying with your phone (Flik, Apple Pay…)
  • Q10e - Neobanks (Revolut, N26…)

Q11 - How easy do you find the following payment methods to use?

  • Q11a - Cash
  • Q11b - (Physical) Debit Card
  • Q11c - (Physical) Credit Card
  • Q11d - Paying with your phone (Flik, Apple Pay…)
  • Q11e - Neobanks (Revolut, N26…)

Q12 - How accepted do you think the following payment methods are in stores in your environment?

  • Q12a - Cash
  • Q12b - (Physical) Debit Card
  • Q12c - (Physical) Credit Card
  • Q12d - Paying with your phone (Flik, Apple Pay…)
  • Q12e - Neobanks (Revolut, N26…)

Q13 - What do you consider the fastest payment method?

  • Q13a - Cash
  • Q13b - (Physical) Debit Card
  • Q13c - (Physical) Credit Card
  • Q13d - Paying with your phone (Flik, Apple Pay…)
  • Q13e - Neobanks (Revolut, N26…)

Q14 - Which payment method do you consider the most private?

  • Q14a - Cash
  • Q14b - (Physical) Debit Card
  • Q14c - (Physical) Credit Card
  • Q14d - Paying with your phone (Flik, Apple Pay…)
  • Q14e - Neobanks (Revolut, N26…)

Q15 - Which payment method helps you control spending the most?

  • Q15a - Cash
  • Q15b - (Physical) Debit Card
  • Q15c - (Physical) Credit Card
  • Q15d - Paying with your phone (Flik, Apple Pay…)
  • Q15e - Neobanks (Revolut, N26…)

Q16 - Social influence on payment method choice.

  • Q16a - I choose the payment methods my friends choose.
  • Q16b - I choose the payment methods my family members choose.

Q17 - How do you most often share expenses among friends?

  • Q17a - With cash
  • Q17b - Through mobile applications (Flik, Revolut, PayPal…)
  • Q17c - By bank transfer
  • Q17d - I don’t share expenses among friends
  • Q17e - Other (please specify)

Q18 - Reasons for preferring digital payments.

  • Q18a - I can quote the exact sum.
  • Q18b - To avoid paying with cash.
  • Q18c - Because the process is quick and convenient.
  • Q18d - Because I have my transactions recorded and it is easier to manage finances.
  • Q18e - Other (please specify).

Q19 - Concerns about digital payment security.

  • Q19a - Fraud (e.g., stealing money)
  • Q19b - Disclosure of Personal Information
  • Q19c - Identity theft
  • Q19d - Loss of access due to a hacker attack

Q20 - Experience with online fraud.

  • Q20a - Yes, it happened to me.
  • Q20b - Yes, I know people who have had this happen.
  • Q20c - Yes, it has happened to me and others I know.
  • Q20d - I’ve never encountered such a situation.

Q21 - How did this affect your behavior in further payment habits?

  • Q21a - I use cash more often in unfamiliar or suspicious situations (e.g., when traveling).
  • Q21b - I use digital payment methods (e.g., virtual or disposable cards facilitated by neobanks) more often in unfamiliar or suspicious situations.
  • Q21c - I am more cautious with online payments.
  • Q21d - I switched to more secure payment options (e.g., mobile wallets with authentication).
  • Q21e - My behavior hasn’t changed.

Q22 - If we had the opportunity, would you switch to digital payments entirely?

  • Q22a - Yes, immediately.
  • Q22b - I would consider it, but I wouldn’t want to give up cash completely.
  • Q22c - No, I prefer to use cash.
  • Q22d - I don’t know.

Q23 - What is your gender?

  • Q23a - Man.
  • Q23b - Woman.
  • Q23c - Another.
  • Q23d - I don’t want to answer.

Q24 - What is your highest level of educational attainment?

  • Q24a - Unfinished primary school.
  • Q24b - Completed primary school.
  • Q24c - Completed lower or secondary vocational education.
  • Q24d - Completed secondary professional or general education.
  • Q24e - Completed tertiary professional or tertiary professional education (including 1st Bologna level).

Q25 - What is your current status?

  • Q25a - Student.
  • Q25b - Employed.
  • Q25c - Self-employed.
  • Q25d - Unemployed.
  • Q25e - Other (please specify).

Q26 - What is your current net monthly income?

  • Q26a - 0-200 EUR.
  • Q26b - 201-500 EUR.
  • Q26c - 501-800 EUR.
  • Q26d - 801-1300 EUR.
  • Q26e - More than 1300 EUR.

Q27 - Which bank do you currently use as your primary bank?

  • Q27a - NLB.
  • Q27b - OTP.
  • Q27c - Intesa Sanpaolo.
  • Q27d - Sparkasse.
  • Q27e - Addiko Bank.
  • Q27f - Workers’ Savings Bank.
  • Q27g - Other (please specify).

Data manipulation

#Remove first row
NLB_data <- NLB_data[-1, ]

#Remove all questionnaires with non valid status
library(dplyr)

NLB_data <- NLB_data %>%
  filter(!status == 5)

#Remove status column
NLB_data <- NLB_data[ , -1]

#Remove all under 18/over 27
library(dplyr)

NLB_data <- NLB_data %>%
 filter(!Q1 %in% c(1, 12))
# Factoring

# Age (Q1)
NLB_data$Q1F <- factor(NLB_data$Q1,
                       levels = c(2:11),
                       labels = c(18:27))

# Q5
NLB_data$Q5F <- factor(NLB_data$Q5,
                       levels = c(1, 2, 3, 4),
                       labels = c("Pay digital elsewhere", "Pay as available", "Never occurred", "Other"))

# Q7

NLB_data$Q7F <- factor(NLB_data$Q7,
                       levels = c(1, 2),
                       labels = c("Yes", "No"))


# Q17

NLB_data$Q17F <- factor(NLB_data$Q17,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Mobile apps", "Bank transfer", "Don't share", "Other"))

# Q20

NLB_data$Q20F <- factor(NLB_data$Q20,
                       levels = c(1, 2, 3, 4),
                       labels = c("Yes - me", "Yes - others", "Yes - both", "No"))


# Q22

NLB_data$Q22F <- factor(NLB_data$Q22,
                       levels = c(1, 2, 3, 4),
                       labels = c("Fully digital", "Balance digital-cash", "Cash", "Don't know"))

# Q23

NLB_data$Q23F <- factor(NLB_data$Q23,
                       levels = c(1, 2, 3, 4),
                       labels = c("Man", "Woman", "Other", "Don't want to answer"))

# Q24

NLB_data$Q24F <- factor(NLB_data$Q24,
                       levels = c(1, 2, 3, 4, 5, 6, 7),
                       labels = c("Unfinished primary", "Primary school", "Vocational education", "High School", "Bachelor Degree", "Master Degree", "PhD" ))

# Q25

NLB_data$Q25F <- factor(NLB_data$Q25,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Student", "Employed", "Self-employed", "Unemployed", "Other"))

# Q26

NLB_data$Q26F <- factor(NLB_data$Q26,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("0-200 EUR", "201-500 EUR", "501-800 EUR", "801-1300 EUR", "Above 1300 EUR"))

# Q27

NLB_data$Q27F <- factor(NLB_data$Q27,
                       levels = c(1, 2, 3, 4, 5, 6, 7),
                       labels = c("NLB", "OTP", "Intesa Sanpaolo", "Sparkasse", "Addiko Bank", "Delovska Hranilnica", "Other"))
#Q3

NLB_data$Q3a <- factor(NLB_data$Q3a,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "1-3 monthly", "1 per week", "Several times a week", "Daily"))
NLB_data$Q3b <- factor(NLB_data$Q3b,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "1-3 monthly", "1 per week", "Several times a week", "Daily"))
NLB_data$Q3c <- factor(NLB_data$Q3c,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "1-3 monthly", "1 per week", "Several times a week", "Daily"))
NLB_data$Q3d <- factor(NLB_data$Q3d,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "1-3 monthly", "1 per week", "Several times a week", "Daily"))
#Q4

NLB_data$Q4a <- factor(NLB_data$Q4a,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "Less than half", "Half", "More than half", "Always"))
NLB_data$Q4b <- factor(NLB_data$Q4b,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "Less than half", "Half", "More than half", "Always"))
NLB_data$Q4c <- factor(NLB_data$Q4c,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "Less than half", "Half", "More than half", "Always"))
NLB_data$Q4d <- factor(NLB_data$Q4d,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Never", "Less than half", "Half", "More than half", "Always"))
#Q6 

NLB_data$Q6a <- factor(NLB_data$Q6a,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
#Q6 

NLB_data$Q6b <- factor(NLB_data$Q6b,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
#Q6 

NLB_data$Q6c <- factor(NLB_data$Q6c,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
#Q6 

NLB_data$Q6d <- factor(NLB_data$Q6d,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
#Q6 

NLB_data$Q6e <- factor(NLB_data$Q6e,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
#Q6 

NLB_data$Q6f <- factor(NLB_data$Q6f,
                       levels = c(1, 2, 3, 4, 5),
                       labels = c("Cash", "Cash&Digitally", "Digitally", "Not using", "Don't want to answer"))
head(NLB_data)
##   Q1         Q3a                  Q3b                  Q3c         Q3d
## 1  7  1 per week          1-3 monthly                Daily 1-3 monthly
## 2  9 1-3 monthly                Daily                Never       Never
## 3  9 1-3 monthly Several times a week Several times a week       Never
## 4  7  1 per week                Daily                Daily       Never
## 5  7 1-3 monthly                Daily                Daily       Never
## 6  9  1 per week           1 per week                Never 1-3 monthly
##              Q4a            Q4b            Q4c   Q4d Q5 Q5_4_text       Q6a
## 1 More than half           Half Less than half Never  2        -2 Digitally
## 2 Less than half          Never          Never Never  1        -2 Not using
## 3 Less than half Less than half          Never Never  2        -2 Digitally
## 4 Less than half Less than half          Never Never  1        -2 Digitally
## 5 Less than half          Never          Never Never  1        -2 Not using
## 6 More than half           Half Less than half Never  2        -2 Digitally
##              Q6b            Q6c       Q6d       Q6e       Q6f Q6g Q7 Q8a Q9a
## 1 Cash&Digitally           Cash      Cash Digitally Digitally   3  1   5   6
## 2 Cash&Digitally           Cash Not using Not using Not using   3  1   7   7
## 3      Digitally           Cash Not using Not using Not using   2  1   7   6
## 4      Digitally Cash&Digitally Not using Not using Digitally   4  1   7   6
## 5      Digitally      Digitally Not using Not using Not using   4  2  -2   7
## 6      Not using           Cash      Cash Digitally Digitally   4  2  -2   7
##   Q9b Q9c Q9d Q9e Q9f Q9g Q9h Q31_2a Q31_2b Q31_2c Q31_2d Q31_2e Q31_2f Q10a
## 1   3   5   6   4   7   6   7      7      7      6      6      3      6    6
## 2   6   3   6   3   7   1   6      6      7      5      7      7      6    3
## 3   2   3   6   3   7   1   7      7      6      6      6      4      5    6
## 4   5   6   7   4   7   1   7      7      7      7      7      7      7    6
## 5   4   7   4   4   7   4   7      7      7      7      7      7      7    7
## 6   3   5   7   7   5   6   5      5      3      7      7      4      4    7
##   Q10b Q10c Q10d Q10e Q11a Q11b Q11c Q11d Q11e Q12a Q12b Q12c Q12d Q12e Q13a
## 1    6    6    7    6    5    6    6    7    6    6    7    7    7    6    5
## 2    7    7    3    6    7    7    7    6    6    6    6    6    6    6    5
## 3    6    4    6    6    4    7    7    7    7    7    7    7    7    7    4
## 4    5    4    6    6    3    6    6    7    7    6    7    7    6    6    1
## 5    4    4    4    4    7    7    7    7    7    7    7    7    7    4    7
## 6    6    6    5    5    6    7    7    6    6    6    7    7    6    6    2
##   Q13b Q13c Q13d Q13e Q14a Q14b Q14c Q14d Q14e Q15a Q15b Q15c Q15d Q15e Q16a
## 1    6    6    7    7    7    6    5    5    6    7    5    5    3    3    5
## 2    7    7    7    7    7    1    1    1    1    2    7    4    1    6    4
## 3    7    7    7    7    6    5    5    5    5    5    7    7    7    7    4
## 4    6    6    7    7    7    4    4    4    4    6    5    1    5    5    7
## 5    7    7    7    7    4    7    7    7    7    4    7    7    7    7    4
## 6    7    7    6    6    5    7    7    7    7    7    6    5    3    5    3
##   Q16b Q17 Q17_5_text Q18a Q18b Q18c Q18d Q18e Q18e_text Q19a Q19b Q19c Q19d
## 1    2   2         -2    1    0    1    0    0        -2    3    5    3    3
## 2    4   2         -2    1    1    1    0    0        -2    5    5    6    7
## 3    4   2         -2    1    1    1    1    0        -2    3    3    3    3
## 4    7   2         -2    1    1    1    1    0        -2    5    5    5    6
## 5    4   2         -2    1    1    1    1    0        -2    7    7    7    7
## 6    5   2         -2    1    0    0    0    0        -2    5    4    6    6
##   Q20 Q21a Q21b Q21c Q21d Q21e Q22 Q23 Q24 Q25 Q25_5_text Q26 Q27 Q27_7_text
## 1   2    0    0    1    0    0   2   1   6   1         -2   2   2         -2
## 2   3    0    0    1    0    0   2   2   5   1         -2   2   2         -2
## 3   4   -2   -2   -2   -2   -2   2   2   4   1         -2   3   7  Unicredit
## 4   4   -2   -2   -2   -2   -2   1   2   4   1         -2   2   1         -2
## 5   1   -1   -1   -1   -1   -1   1   2   4   1         -2   4   1         -2
## 6   2    1    0    0    0    0   4   2   6   1         -2   2   1         -2
##   Q1F                   Q5F Q7F        Q17F         Q20F                 Q22F
## 1  23      Pay as available Yes Mobile apps Yes - others Balance digital-cash
## 2  25 Pay digital elsewhere Yes Mobile apps   Yes - both Balance digital-cash
## 3  25      Pay as available Yes Mobile apps           No Balance digital-cash
## 4  23 Pay digital elsewhere Yes Mobile apps           No        Fully digital
## 5  23 Pay digital elsewhere  No Mobile apps     Yes - me        Fully digital
## 6  25      Pay as available  No Mobile apps Yes - others           Don't know
##    Q23F            Q24F    Q25F         Q26F  Q27F
## 1   Man   Master Degree Student  201-500 EUR   OTP
## 2 Woman Bachelor Degree Student  201-500 EUR   OTP
## 3 Woman     High School Student  501-800 EUR Other
## 4 Woman     High School Student  201-500 EUR   NLB
## 5 Woman     High School Student 801-1300 EUR   NLB
## 6 Woman   Master Degree Student  201-500 EUR   NLB

Descriptive statistics

library(dplyr)

# Convert character columns in specified ranges to numeric
NLB_data <- NLB_data %>%
  mutate(across(c(2:9, 11:18, 21:66, 68:78, 80:84, 89, 92), 
                ~ ifelse(!is.na(.), as.numeric(.), .)))
## Warning: There were 5 warnings in `mutate()`.
## The first warning was:
## ℹ In argument: `across(...)`.
## Caused by warning in `ifelse()`:
## ! NAs introduced by coercion
## ℹ Run `dplyr::last_dplyr_warnings()` to see the 4 remaining warnings.
summary(NLB_data)
##       Q1                 Q3a             Q3b            Q3c       
##  Length:304         Min.   :1.000   Min.   :1.00   Min.   :1.000  
##  Class :character   1st Qu.:2.000   1st Qu.:2.00   1st Qu.:1.000  
##  Mode  :character   Median :2.000   Median :4.00   Median :4.000  
##                     Mean   :2.737   Mean   :3.51   Mean   :3.332  
##                     3rd Qu.:4.000   3rd Qu.:4.00   3rd Qu.:5.000  
##                     Max.   :5.000   Max.   :5.00   Max.   :5.000  
##                                                                   
##       Q3d             Q4a             Q4b            Q4c             Q4d       
##  Min.   :1.000   Min.   :1.000   Min.   :1.00   Min.   :1.000   Min.   :1.000  
##  1st Qu.:1.000   1st Qu.:2.000   1st Qu.:1.00   1st Qu.:1.000   1st Qu.:1.000  
##  Median :1.000   Median :2.000   Median :2.00   Median :1.000   Median :1.000  
##  Mean   :1.546   Mean   :2.421   Mean   :2.03   Mean   :1.576   Mean   :1.398  
##  3rd Qu.:2.000   3rd Qu.:3.000   3rd Qu.:2.00   3rd Qu.:2.000   3rd Qu.:1.000  
##  Max.   :5.000   Max.   :5.000   Max.   :5.00   Max.   :5.000   Max.   :5.000  
##                                                                                
##       Q5              Q5_4_text       Q6a             Q6b             Q6c      
##  Length:304         Min.   :-2   Min.   :1.000   Min.   :1.000   Min.   :1.00  
##  Class :character   1st Qu.:-2   1st Qu.:3.000   1st Qu.:1.750   1st Qu.:1.00  
##  Mode  :character   Median :-2   Median :3.000   Median :3.000   Median :1.00  
##                     Mean   :-2   Mean   :2.905   Mean   :2.651   Mean   :1.28  
##                     3rd Qu.:-2   3rd Qu.:3.000   3rd Qu.:4.000   3rd Qu.:1.00  
##                     Max.   :-2   Max.   :4.000   Max.   :5.000   Max.   :5.00  
##                     NA's   :15                                                 
##       Q6d             Q6e             Q6f             Q6g       
##  Min.   :1.000   Min.   :1.000   Min.   :2.000   Min.   :1.000  
##  1st Qu.:1.000   1st Qu.:4.000   1st Qu.:3.000   1st Qu.:3.000  
##  Median :4.000   Median :4.000   Median :4.000   Median :4.000  
##  Mean   :3.039   Mean   :3.796   Mean   :3.539   Mean   :3.674  
##  3rd Qu.:4.000   3rd Qu.:4.000   3rd Qu.:4.000   3rd Qu.:4.000  
##  Max.   :5.000   Max.   :5.000   Max.   :5.000   Max.   :5.000  
##                                                                 
##       Q7                 Q8a              Q9a             Q9b       
##  Length:304         Min.   :-2.000   Min.   :1.000   Min.   :1.000  
##  Class :character   1st Qu.: 1.000   1st Qu.:4.000   1st Qu.:1.000  
##  Mode  :character   Median : 4.000   Median :6.000   Median :3.000  
##                     Mean   : 3.395   Mean   :5.316   Mean   :3.115  
##                     3rd Qu.: 7.000   3rd Qu.:7.000   3rd Qu.:4.000  
##                     Max.   : 7.000   Max.   :7.000   Max.   :7.000  
##                                                                     
##       Q9c             Q9d             Q9e             Q9f       
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:2.000   1st Qu.:4.000   1st Qu.:3.000   1st Qu.:6.000  
##  Median :4.000   Median :6.000   Median :4.000   Median :7.000  
##  Mean   :3.655   Mean   :5.359   Mean   :4.135   Mean   :6.046  
##  3rd Qu.:5.000   3rd Qu.:7.000   3rd Qu.:5.000   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q9g             Q9h            Q31_2a          Q31_2b      Q31_2c     
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1   Min.   :1.000  
##  1st Qu.:1.000   1st Qu.:5.000   1st Qu.:6.000   1st Qu.:6   1st Qu.:6.000  
##  Median :4.000   Median :6.000   Median :7.000   Median :7   Median :7.000  
##  Mean   :3.441   Mean   :5.704   Mean   :6.105   Mean   :6   Mean   :6.168  
##  3rd Qu.:5.000   3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7   Max.   :7.000  
##                                                                             
##      Q31_2d          Q31_2e          Q31_2f           Q10a      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:5.000   1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000  
##  Median :7.000   Median :5.000   Median :6.000   Median :6.000  
##  Mean   :6.076   Mean   :5.201   Mean   :5.658   Mean   :5.503  
##  3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q10b            Q10c            Q10d            Q10e      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000  
##  Median :5.000   Median :5.000   Median :5.000   Median :5.000  
##  Mean   :5.138   Mean   :4.947   Mean   :5.174   Mean   :4.826  
##  3rd Qu.:6.000   3rd Qu.:6.000   3rd Qu.:7.000   3rd Qu.:6.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q11a            Q11b            Q11c           Q11d           Q11e      
##  Min.   :1.000   Min.   :3.000   Min.   :3.00   Min.   :1.00   Min.   :1.000  
##  1st Qu.:4.000   1st Qu.:5.000   1st Qu.:5.00   1st Qu.:7.00   1st Qu.:4.000  
##  Median :5.000   Median :7.000   Median :7.00   Median :7.00   Median :6.000  
##  Mean   :5.102   Mean   :6.148   Mean   :6.02   Mean   :6.48   Mean   :5.592  
##  3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.00   3rd Qu.:7.00   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.00   Max.   :7.00   Max.   :7.000  
##                                                                               
##       Q12a            Q12b            Q12c            Q12d           Q12e      
##  Min.   :1.000   Min.   :3.000   Min.   :2.000   Min.   :1.00   Min.   :1.000  
##  1st Qu.:6.000   1st Qu.:6.000   1st Qu.:6.000   1st Qu.:5.00   1st Qu.:4.000  
##  Median :7.000   Median :7.000   Median :7.000   Median :7.00   Median :5.000  
##  Mean   :6.227   Mean   :6.484   Mean   :6.336   Mean   :6.03   Mean   :5.076  
##  3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.00   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.00   Max.   :7.000  
##                                                                                
##       Q13a            Q13b            Q13c            Q13d      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:2.750   1st Qu.:5.000   1st Qu.:5.000   1st Qu.:7.000  
##  Median :4.000   Median :7.000   Median :7.000   Median :7.000  
##  Mean   :4.076   Mean   :6.174   Mean   :6.122   Mean   :6.526  
##  3rd Qu.:6.000   3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q13e            Q14a            Q14b            Q14c      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000  
##  Median :6.000   Median :7.000   Median :4.000   Median :4.000  
##  Mean   :5.684   Mean   :5.681   Mean   :4.457   Mean   :4.457  
##  3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:6.000   3rd Qu.:6.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q14d            Q14e            Q15a            Q15b      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:3.000   1st Qu.:4.000   1st Qu.:3.000   1st Qu.:4.000  
##  Median :4.000   Median :4.000   Median :5.000   Median :5.000  
##  Mean   :4.395   Mean   :4.484   Mean   :4.852   Mean   :5.155  
##  3rd Qu.:6.000   3rd Qu.:6.000   3rd Qu.:7.000   3rd Qu.:7.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q15c            Q15d            Q15e            Q16a      
##  Min.   :1.000   Min.   :1.000   Min.   :1.000   Min.   :1.000  
##  1st Qu.:4.000   1st Qu.:4.000   1st Qu.:4.000   1st Qu.:1.000  
##  Median :5.000   Median :5.000   Median :5.000   Median :3.000  
##  Mean   :5.007   Mean   :5.161   Mean   :5.115   Mean   :3.125  
##  3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:7.000   3rd Qu.:4.000  
##  Max.   :7.000   Max.   :7.000   Max.   :7.000   Max.   :7.000  
##                                                                 
##       Q16b           Q17              Q17_5_text      Q18a        
##  Min.   :1.000   Length:304         Min.   :-2   Min.   :-2.0000  
##  1st Qu.:1.000   Class :character   1st Qu.:-2   1st Qu.: 1.0000  
##  Median :4.000   Mode  :character   Median :-2   Median : 1.0000  
##  Mean   :3.339                      Mean   :-2   Mean   : 0.5132  
##  3rd Qu.:5.000                      3rd Qu.:-2   3rd Qu.: 1.0000  
##  Max.   :7.000                      Max.   :-2   Max.   : 1.0000  
##                                     NA's   :4                     
##       Q18b              Q18c              Q18d              Q18e        
##  Min.   :-2.0000   Min.   :-2.0000   Min.   :-2.0000   Min.   :-2.0000  
##  1st Qu.: 0.0000   1st Qu.: 1.0000   1st Qu.: 0.0000   1st Qu.: 0.0000  
##  Median : 0.0000   Median : 1.0000   Median : 0.0000   Median : 0.0000  
##  Mean   : 0.1579   Mean   : 0.5164   Mean   : 0.1349   Mean   :-0.2368  
##  3rd Qu.: 1.0000   3rd Qu.: 1.0000   3rd Qu.: 1.0000   3rd Qu.: 0.0000  
##  Max.   : 1.0000   Max.   : 1.0000   Max.   : 1.0000   Max.   : 1.0000  
##                                                                         
##    Q18e_text           Q19a             Q19b             Q19c       
##  Min.   :-2.000   Min.   :-1.000   Min.   :-1.000   Min.   :-1.000  
##  1st Qu.:-2.000   1st Qu.: 4.000   1st Qu.: 4.000   1st Qu.: 3.000  
##  Median :-2.000   Median : 5.000   Median : 4.000   Median : 4.000  
##  Mean   :-1.997   Mean   : 4.507   Mean   : 4.457   Mean   : 4.273  
##  3rd Qu.:-2.000   3rd Qu.: 6.000   3rd Qu.: 6.000   3rd Qu.: 6.000  
##  Max.   :-1.000   Max.   : 7.000   Max.   : 7.000   Max.   : 7.000  
##  NA's   :7                                                          
##       Q19d            Q20                 Q21a             Q21b       
##  Min.   :-1.000   Length:304         Min.   :-2.000   Min.   :-2.000  
##  1st Qu.: 4.000   Class :character   1st Qu.:-2.000   1st Qu.:-2.000  
##  Median : 5.000   Mode  :character   Median :-2.000   Median :-2.000  
##  Mean   : 4.849                      Mean   :-1.039   Mean   :-1.072  
##  3rd Qu.: 6.000                      3rd Qu.: 0.000   3rd Qu.: 0.000  
##  Max.   : 7.000                      Max.   : 1.000   Max.   : 1.000  
##                                                                       
##       Q21c              Q21d             Q21e            Q22           
##  Min.   :-2.0000   Min.   :-2.000   Min.   :-2.000   Length:304        
##  1st Qu.:-2.0000   1st Qu.:-2.000   1st Qu.:-2.000   Class :character  
##  Median :-2.0000   Median :-2.000   Median :-2.000   Mode  :character  
##  Mean   :-0.8651   Mean   :-1.033   Mean   :-1.079                     
##  3rd Qu.: 1.0000   3rd Qu.: 0.000   3rd Qu.: 0.000                     
##  Max.   : 1.0000   Max.   : 1.000   Max.   : 1.000                     
##                                                                        
##      Q23                Q24                Q25              Q25_5_text
##  Length:304         Length:304         Length:304         Min.   :-2  
##  Class :character   Class :character   Class :character   1st Qu.:-2  
##  Mode  :character   Mode  :character   Mode  :character   Median :-2  
##                                                           Mean   :-2  
##                                                           3rd Qu.:-2  
##                                                           Max.   :-2  
##                                                           NA's   :9   
##      Q26                Q27              Q27_7_text      Q1F    
##  Length:304         Length:304         Min.   :-2   23     :64  
##  Class :character   Class :character   1st Qu.:-2   22     :44  
##  Mode  :character   Mode  :character   Median :-2   25     :43  
##                                        Mean   :-2   20     :40  
##                                        3rd Qu.:-2   24     :30  
##                                        Max.   :-2   21     :23  
##                                        NA's   :23   (Other):60  
##                     Q5F       Q7F                 Q17F               Q20F    
##  Pay digital elsewhere: 52   Yes:233   Cash         : 28   Yes - me    : 22  
##  Pay as available     :195   No : 71   Mobile apps  :250   Yes - others: 96  
##  Never occurred       : 42             Bank transfer: 14   Yes - both  : 11  
##  Other                : 15             Don't share  :  8   No          :172  
##                                        Other        :  4   NA's        :  3  
##                                                                              
##                                                                              
##                    Q22F                       Q23F    
##  Fully digital       : 78   Man                 :120  
##  Balance digital-cash:171   Woman               :182  
##  Cash                : 44   Other               :  1  
##  Don't know          : 10   Don't want to answer:  1  
##  NA's                :  1                             
##                                                       
##                                                       
##                    Q24F                Q25F                 Q26F   
##  Unfinished primary  :  0   Student      :236   0-200 EUR     :48  
##  Primary school      :  8   Employed     : 49   201-500 EUR   :91  
##  Vocational education:  2   Self-employed:  7   501-800 EUR   :58  
##  High School         :132   Unemployed   :  3   801-1300 EUR  :48  
##  Bachelor Degree     : 99   Other        :  9   Above 1300 EUR:57  
##  Master Degree       : 61                       NA's          : 2  
##  PhD                 :  2                                          
##                   Q27F    
##  NLB                :121  
##  OTP                :109  
##  Intesa Sanpaolo    : 17  
##  Sparkasse          :  7  
##  Addiko Bank        :  8  
##  Delovska Hranilnica: 19  
##  Other              : 23

Categorical variables

  • Q17 – Preferred Payment Method for Expense Sharing When it comes to sharing expenses, the majority of respondents (250) prefer using mobile apps. A smaller group (28) opts for cash, while 14 respondents use bank transfers. Eight respondents do not share expenses with others, and four selected “Other” as their method of choice. This highlights the dominance of mobile apps as the most convenient and preferred option for managing shared expenses.
  • Q22 – Savings Preference Respondents show varied saving preferences. A majority (171) save their money in a balanced form, splitting between digital and cash. Fully digital savings are preferred by 78 respondents, while 44 save entirely in cash. A smaller group (10 respondents) is unsure of their savings method.
  • Q23 – Gender The gender distribution indicates that the majority of respondents (182) are women, while 120 are men. Additionally, 1 respondent identified as “Other,” and another preferred not to disclose their gender.
  • Q24 – Education Level The most common level of education is high school completion, with 132 respondents. Following this, 99 have a bachelor’s degree, 61 hold a master’s degree, and 2 have a PhD. Vocational education was reported by 2 respondents, and 8 completed only primary school, while none reported having incomplete primary education.
  • Q25 – Employment Status The majority of respondents (236) are students. Employed individuals account for 49 responses, followed by 7 self-employed, 3 unemployed, and 9 selecting “other” as their employment status.
  • Q26 – Monthly Income Regarding income, the largest group of respondents (91) earns between 201-500 EUR per month. Others reported the following income ranges: 0-200 EUR (48), 501-800 EUR (58), 801-1300 EUR (48), and above 1300 EUR (57).
  • Q27 – Bank Association Respondents are primarily associated with two major banks: NLB (121 respondents) and OTP (109 respondents). Smaller numbers of respondents use other banks such as Intesa Sanpaolo (17), Sparkasse (7), and Addiko Bank (8).

Numerical variables

Respondents show varying frequencies of cash usage based on the purchase amount. For small purchases (up to €10), the average usage is moderate, with a mean of 2.421 and a median of 2, indicating that cash is used occasionally but not regularly. Medium-small purchases (€11 to €99) have a slightly higher mean of 2.737 but still lean towards occasional use, with a median of 2. In contrast, for medium-large purchases (€100 to €1000), cash usage drops significantly, reflected by a mean of 1.576 and a median of 1, suggesting infrequent or rare use. This trend continues for large purchases (over €1000), where cash is almost never used, with a mean of 1.398 and a median of 1. Overall, cash usage declines as the purchase value increases, indicating a preference for alternative payment methods for higher-value transactions.

Respondents show a stronger tendency to be influenced by their family than by their friends when choosing payment methods. For Q16a (friends’ influence), the mean is 3.125 and the median is 3, indicating a neutral to slightly agreeing stance, with many respondents either disagreeing or moderately agreeing. In contrast, Q16b (family’s influence) has a higher mean of 3.339 and a median of 4, suggesting a more significant agreement with the statement. While both questions have a 1st quartile of 1, indicating strong disagreement from a subset of respondents, the 3rd quartile for family influence is 5, compared to 4 for friends, confirming that family has a stronger impact on respondents’ payment choices.

Creating PCA for clustering

NLB_PCA10 <- NLB_data[ , c("Q10b", "Q10c", "Q10d", "Q10e")]

NLB_PCA11 <- NLB_data[ , c("Q11b", "Q11c", "Q11d", "Q11e")]

NLB_PCA12 <- NLB_data[ , c("Q12b", "Q12c", "Q12d", "Q12e")]

NLB_PCA13 <- NLB_data[ , c("Q13b", "Q13c", "Q13d", "Q13e")]

NLB_PCA14 <- NLB_data[ , c("Q14b", "Q14c", "Q14d", "Q14e")]

NLB_PCA15 <- NLB_data[ , c("Q15b", "Q15c", "Q15d", "Q15e")]

library(pastecs)
## 
## Attaching package: 'pastecs'
## The following objects are masked from 'package:dplyr':
## 
##     first, last
round(stat.desc(NLB_PCA10, basic = FALSE), 2)
##              Q10b Q10c Q10d Q10e
## median       5.00 5.00 5.00 5.00
## mean         5.14 4.95 5.17 4.83
## SE.mean      0.07 0.08 0.09 0.09
## CI.mean.0.95 0.14 0.15 0.17 0.17
## var          1.58 1.85 2.28 2.30
## std.dev      1.26 1.36 1.51 1.52
## coef.var     0.25 0.28 0.29 0.31
round(stat.desc(NLB_PCA11, basic = FALSE), 2)
##              Q11b Q11c Q11d Q11e
## median       7.00 7.00 7.00 6.00
## mean         6.15 6.02 6.48 5.59
## SE.mean      0.06 0.07 0.06 0.09
## CI.mean.0.95 0.13 0.14 0.12 0.17
## var          1.26 1.45 1.22 2.31
## std.dev      1.12 1.20 1.10 1.52
## coef.var     0.18 0.20 0.17 0.27
round(stat.desc(NLB_PCA12, basic = FALSE), 2)
##              Q12b Q12c Q12d Q12e
## median       7.00 7.00 7.00 5.00
## mean         6.48 6.34 6.03 5.08
## SE.mean      0.05 0.06 0.07 0.10
## CI.mean.0.95 0.11 0.13 0.14 0.19
## var          0.88 1.24 1.51 2.81
## std.dev      0.94 1.11 1.23 1.68
## coef.var     0.14 0.18 0.20 0.33
round(stat.desc(NLB_PCA13, basic = FALSE), 2)
##              Q13b Q13c Q13d Q13e
## median       7.00 7.00 7.00 6.00
## mean         6.17 6.12 6.53 5.68
## SE.mean      0.07 0.07 0.06 0.08
## CI.mean.0.95 0.13 0.14 0.12 0.17
## var          1.34 1.47 1.08 2.18
## std.dev      1.16 1.21 1.04 1.48
## coef.var     0.19 0.20 0.16 0.26
round(stat.desc(NLB_PCA14, basic = FALSE), 2)
##              Q14b Q14c Q14d Q14e
## median       4.00 4.00 4.00 4.00
## mean         4.46 4.46 4.39 4.48
## SE.mean      0.10 0.10 0.10 0.09
## CI.mean.0.95 0.20 0.20 0.20 0.19
## var          3.01 2.99 3.22 2.71
## std.dev      1.73 1.73 1.80 1.64
## coef.var     0.39 0.39 0.41 0.37
round(stat.desc(NLB_PCA15, basic = FALSE), 2)
##              Q15b Q15c Q15d Q15e
## median       5.00 5.00 5.00 5.00
## mean         5.15 5.01 5.16 5.12
## SE.mean      0.10 0.10 0.11 0.10
## CI.mean.0.95 0.19 0.20 0.21 0.19
## var          2.92 3.03 3.38 2.84
## std.dev      1.71 1.74 1.84 1.69
## coef.var     0.33 0.35 0.36 0.33
library(FactoMineR)
components10 <- PCA(NLB_PCA10,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
library(FactoMineR)
components11 <- PCA(NLB_PCA11,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
library(FactoMineR)
components12 <- PCA(NLB_PCA12,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
library(FactoMineR)
components13 <- PCA(NLB_PCA13,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
library(FactoMineR)
components14 <- PCA(NLB_PCA14,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
library(FactoMineR)
components15 <- PCA(NLB_PCA15,
                  scale.unit = TRUE,
                  graph = FALSE,
                  ncp = 1)
NLB_data$PC10 <- components10$ind$coord[ , 1]
NLB_data$PC11 <- components11$ind$coord[ , 1]
NLB_data$PC12 <- components12$ind$coord[ , 1]
NLB_data$PC13 <- components13$ind$coord[ , 1]
NLB_data$PC14 <- components14$ind$coord[ , 1]
NLB_data$PC15 <- components15$ind$coord[ , 1]

head(NLB_data)
##   Q1 Q3a Q3b Q3c Q3d Q4a Q4b Q4c Q4d Q5 Q5_4_text Q6a Q6b Q6c Q6d Q6e Q6f Q6g
## 1  7   3   2   5   2   4   3   2   1  2        -2   3   2   1   1   3   3   3
## 2  9   2   5   1   1   2   1   1   1  1        -2   4   2   1   4   4   4   3
## 3  9   2   4   4   1   2   2   1   1  2        -2   3   3   1   4   4   4   2
## 4  7   3   5   5   1   2   2   1   1  1        -2   3   3   2   4   4   3   4
## 5  7   2   5   5   1   2   1   1   1  1        -2   4   3   3   4   4   4   4
## 6  9   3   3   1   2   4   3   2   1  2        -2   3   4   1   1   3   3   4
##   Q7 Q8a Q9a Q9b Q9c Q9d Q9e Q9f Q9g Q9h Q31_2a Q31_2b Q31_2c Q31_2d Q31_2e
## 1  1   5   6   3   5   6   4   7   6   7      7      7      6      6      3
## 2  1   7   7   6   3   6   3   7   1   6      6      7      5      7      7
## 3  1   7   6   2   3   6   3   7   1   7      7      6      6      6      4
## 4  1   7   6   5   6   7   4   7   1   7      7      7      7      7      7
## 5  2  -2   7   4   7   4   4   7   4   7      7      7      7      7      7
## 6  2  -2   7   3   5   7   7   5   6   5      5      3      7      7      4
##   Q31_2f Q10a Q10b Q10c Q10d Q10e Q11a Q11b Q11c Q11d Q11e Q12a Q12b Q12c Q12d
## 1      6    6    6    6    7    6    5    6    6    7    6    6    7    7    7
## 2      6    3    7    7    3    6    7    7    7    6    6    6    6    6    6
## 3      5    6    6    4    6    6    4    7    7    7    7    7    7    7    7
## 4      7    6    5    4    6    6    3    6    6    7    7    6    7    7    6
## 5      7    7    4    4    4    4    7    7    7    7    7    7    7    7    7
## 6      4    7    6    6    5    5    6    7    7    6    6    6    7    7    6
##   Q12e Q13a Q13b Q13c Q13d Q13e Q14a Q14b Q14c Q14d Q14e Q15a Q15b Q15c Q15d
## 1    6    5    6    6    7    7    7    6    5    5    6    7    5    5    3
## 2    6    5    7    7    7    7    7    1    1    1    1    2    7    4    1
## 3    7    4    7    7    7    7    6    5    5    5    5    5    7    7    7
## 4    6    1    6    6    7    7    7    4    4    4    4    6    5    1    5
## 5    4    7    7    7    7    7    4    7    7    7    7    4    7    7    7
## 6    6    2    7    7    6    6    5    7    7    7    7    7    6    5    3
##   Q15e Q16a Q16b Q17 Q17_5_text Q18a Q18b Q18c Q18d Q18e Q18e_text Q19a Q19b
## 1    3    5    2   2         -2    1    0    1    0    0        -2    3    5
## 2    6    4    4   2         -2    1    1    1    0    0        -2    5    5
## 3    7    4    4   2         -2    1    1    1    1    0        -2    3    3
## 4    5    7    7   2         -2    1    1    1    1    0        -2    5    5
## 5    7    4    4   2         -2    1    1    1    1    0        -2    7    7
## 6    5    3    5   2         -2    1    0    0    0    0        -2    5    4
##   Q19c Q19d Q20 Q21a Q21b Q21c Q21d Q21e Q22 Q23 Q24 Q25 Q25_5_text Q26 Q27
## 1    3    3   2    0    0    1    0    0   2   1   6   1         -2   2   2
## 2    6    7   3    0    0    1    0    0   2   2   5   1         -2   2   2
## 3    3    3   4   -2   -2   -2   -2   -2   2   2   4   1         -2   3   7
## 4    5    6   4   -2   -2   -2   -2   -2   1   2   4   1         -2   2   1
## 5    7    7   1   -1   -1   -1   -1   -1   1   2   4   1         -2   4   1
## 6    6    6   2    1    0    0    0    0   4   2   6   1         -2   2   1
##   Q27_7_text Q1F                   Q5F Q7F        Q17F         Q20F
## 1         -2  23      Pay as available Yes Mobile apps Yes - others
## 2         -2  25 Pay digital elsewhere Yes Mobile apps   Yes - both
## 3         NA  25      Pay as available Yes Mobile apps           No
## 4         -2  23 Pay digital elsewhere Yes Mobile apps           No
## 5         -2  23 Pay digital elsewhere  No Mobile apps     Yes - me
## 6         -2  25      Pay as available  No Mobile apps Yes - others
##                   Q22F  Q23F            Q24F    Q25F         Q26F  Q27F
## 1 Balance digital-cash   Man   Master Degree Student  201-500 EUR   OTP
## 2 Balance digital-cash Woman Bachelor Degree Student  201-500 EUR   OTP
## 3 Balance digital-cash Woman     High School Student  501-800 EUR Other
## 4        Fully digital Woman     High School Student  201-500 EUR   NLB
## 5        Fully digital Woman     High School Student 801-1300 EUR   NLB
## 6           Don't know Woman   Master Degree Student  201-500 EUR   NLB
##         PC10      PC11       PC12      PC13       PC14       PC15
## 1 -1.7204789 0.1593095 -1.2385549 0.3545114 -1.2168529 -1.2370388
## 2 -1.1689414 0.9246044  0.2539360 1.3676446  3.9978412 -0.6158432
## 3 -0.6604604 1.4565407 -1.4619345 1.3676446 -0.6395533  2.1738887
## 4 -0.2295463 0.3880241 -0.8265122 0.3545114  0.5197953 -1.2939568
## 5  1.4772851 1.4565407 -0.7917959 1.3676446 -2.9582505  2.1738887
## 6 -0.7464178 0.9246044 -0.8265122 0.7468479 -2.9582505 -0.3666127

Clustering

NLB_CluStd <- as.data.frame(scale(NLB_data[c("PC10", "PC11", "PC12", "PC13", "PC14", "PC15")]))
NLB_CluStd$Dissimilarity <- sqrt(NLB_CluStd$PC10^2 + NLB_CluStd$PC11^2 + NLB_CluStd$PC12^2 + NLB_CluStd$PC13^2 +NLB_CluStd$PC14^2 + NLB_CluStd$PC15^2)
library(factoextra)
## Loading required package: ggplot2
## Welcome! Want to learn more? See two factoextra-related books at https://goo.gl/ve3WBa
Distances <- get_dist(NLB_CluStd,
                      method = "euclidian")

fviz_dist(Distances, 
          gradient = list(low = "blue",
                          mid = "grey",
                          high = "white"))

NLB_CluStd <- NLB_CluStd %>% rename(Security = PC10, 
                                    `Ease of use` = PC11, 
                                    Availability = PC12, 
                                    Speed = PC13, 
                                    Privacy = PC14, 
                                    `Controlling of spending` = PC15)
library(factoextra)
get_clust_tendency(NLB_CluStd,
                   n = nrow(NLB_CluStd) -1,
                   graph = FALSE)
## $hopkins_stat
## [1] 0.6785538
## 
## $plot
## NULL
library(dplyr)
library(factoextra)
WARD <- NLB_CluStd %>%
  get_dist(method = "euclidean") %>%
  hclust(method = "ward.D2")

WARD
## 
## Call:
## hclust(d = ., method = "ward.D2")
## 
## Cluster method   : ward.D2 
## Distance         : euclidean 
## Number of objects: 304
library(factoextra)
fviz_dend(WARD)
## Warning: The `<scale>` argument of `guides()` cannot be `FALSE`. Use "none" instead as
## of ggplot2 3.3.4.
## ℹ The deprecated feature was likely used in the factoextra package.
##   Please report the issue at <https://github.com/kassambara/factoextra/issues>.
## This warning is displayed once every 8 hours.
## Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
## generated.

library(factoextra)
library(NbClust)
fviz_nbclust(NLB_CluStd, kmeans, method = "wss") +
  labs(subtitle = "Elbow Method")

fviz_nbclust(NLB_CluStd, kmeans, method = "silhouette") +
  labs(subtitle = "Silhouette analysis")

Clustering <- kmeans(NLB_CluStd,
                     centers = 4,
                     nstart = 25)
Clustering
## K-means clustering with 4 clusters of sizes 63, 93, 103, 45
## 
## Cluster means:
##     Security Ease of use Availability       Speed    Privacy
## 1  0.4866563   0.4709095  -0.15616090  0.24994550  0.8603929
## 2 -0.7517767   0.7902180  -0.57596893  0.69484422 -0.8043929
## 3  0.1430845  -0.5409715   0.04180835 -0.07174967 -0.0235824
## 4  0.5448485  -1.0541669   1.31326640 -1.62170805  0.5118394
##   Controlling of spending Dissimilarity
## 1              -0.8773218      2.469170
## 2               0.5618051      2.324214
## 3               0.1264165      1.698921
## 4              -0.2221667      3.443997
## 
## Clustering vector:
##   [1] 2 1 2 3 2 2 3 3 3 3 2 3 1 3 2 2 1 3 3 2 1 2 2 4 3 3 3 2 2 4 1 4 3 3 3 2 2
##  [38] 4 2 2 1 2 4 3 3 4 1 3 3 2 4 3 2 2 1 3 2 2 1 3 2 4 1 1 1 1 2 3 3 2 4 1 3 2
##  [75] 2 1 2 1 3 3 1 4 3 1 1 3 3 3 2 3 4 2 1 1 2 2 3 2 4 1 1 2 2 2 3 4 1 2 2 1 3
## [112] 1 1 1 2 3 1 4 2 3 2 1 4 4 1 2 3 2 2 3 1 1 4 2 3 3 4 1 1 4 3 3 2 2 2 4 2 2
## [149] 1 3 2 3 3 1 3 3 2 3 3 2 2 3 2 4 3 3 2 1 4 4 4 2 4 1 2 4 1 1 3 2 3 3 2 3 1
## [186] 3 3 3 4 1 4 3 2 3 4 3 3 3 1 3 1 4 1 4 2 4 4 4 4 3 3 3 2 1 2 3 1 3 2 3 1 3
## [223] 3 3 3 4 2 2 4 2 2 1 2 3 3 2 2 2 2 3 2 3 1 1 3 3 2 2 2 2 2 2 2 4 2 1 3 3 1
## [260] 1 1 3 2 2 3 2 3 3 3 3 2 2 3 3 3 3 3 3 3 3 3 3 2 1 1 1 1 4 1 4 4 2 2 1 2 3
## [297] 3 4 1 4 3 4 2 4
## 
## Within cluster sum of squares by cluster:
## [1] 301.0014 275.2221 329.2284 299.6181
##  (between_SS / total_SS =  40.2 %)
## 
## Available components:
## 
## [1] "cluster"      "centers"      "totss"        "withinss"     "tot.withinss"
## [6] "betweenss"    "size"         "iter"         "ifault"
library(factoextra)
fviz_cluster(Clustering, 
             palette = "Set1",
             repel = FALSE,
             ggtheme = theme_bw(),
             data = NLB_CluStd)

Averages <- Clustering$centers
Averages
##     Security Ease of use Availability       Speed    Privacy
## 1  0.4866563   0.4709095  -0.15616090  0.24994550  0.8603929
## 2 -0.7517767   0.7902180  -0.57596893  0.69484422 -0.8043929
## 3  0.1430845  -0.5409715   0.04180835 -0.07174967 -0.0235824
## 4  0.5448485  -1.0541669   1.31326640 -1.62170805  0.5118394
##   Controlling of spending Dissimilarity
## 1              -0.8773218      2.469170
## 2               0.5618051      2.324214
## 3               0.1264165      1.698921
## 4              -0.2221667      3.443997
Figure <- as.data.frame(Averages)
Figure$id <- 1:nrow(Figure)

library(tidyr)
## 
## Attaching package: 'tidyr'
## The following object is masked from 'package:pastecs':
## 
##     extract
Figure <- pivot_longer(Figure, cols = c("Security", "Ease of use", "Availability", "Speed", "Privacy", "Controlling of spending"))

Figure$Group <- factor(Figure$id, 
                       levels = c(1, 2, 3, 4, 5), 
                       labels = c("1", "2", "3", "4", "5"))

Figure$ImeF <- factor(Figure$name, 
              levels = c("Security", "Ease of use", "Availability", "Speed", "Privacy", "Controlling of spending"), 
              labels = c("Security", "Ease of use", "Availability", "Speed", "Privacy", "Controlling of spending"))


library(ggplot2)
ggplot(Figure, aes(x = ImeF, y = value)) +
  geom_hline(yintercept = 0) +
  theme_bw() +
  geom_point(aes(shape = Group, col = Group), size = 3) +
  geom_line(aes(group = id), linewidth = 1) +
  ylab("Averages") +
  xlab("Cluster variables") +
  scale_color_brewer(palette="Set1") +
  ylim(-3, 3) +
  theme(axis.text.x = element_text(angle = 45, vjust = 0.50, size = 10))

NLB_CluStd$Group <- Clustering$cluster

fit <- aov(cbind(`Security`, `Ease of use`, `Availability`, `Speed`, `Privacy`, `Controlling of spending`) ~ as.factor(Group), 
           data = NLB_CluStd)

summary(fit)
##  Response Security :
##                   Df  Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3  82.949 27.6495  37.695 < 2.2e-16 ***
## Residuals        300 220.051  0.7335                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
##  Response Ease of use :
##                   Df Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3 152.19  50.731  100.92 < 2.2e-16 ***
## Residuals        300 150.81   0.503                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
##  Response Availability :
##                   Df Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3 110.18  36.726   57.14 < 2.2e-16 ***
## Residuals        300 192.82   0.643                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
##  Response Speed :
##                   Df Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3 167.71  55.905  123.97 < 2.2e-16 ***
## Residuals        300 135.29   0.451                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
##  Response Privacy :
##                   Df Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3 118.66  39.553   64.37 < 2.2e-16 ***
## Residuals        300 184.34   0.614                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
##  Response Controlling of spending :
##                   Df  Sum Sq Mean Sq F value    Pr(>F)    
## as.factor(Group)   3  81.711 27.2370  36.925 < 2.2e-16 ***
## Residuals        300 221.289  0.7376                      
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1

FAILED Citerion validity

NLB_data$Group <- NLB_CluStd$Group

Education

NLB_Education <- NLB_data %>% select(110)
NLB_Education$D <- ifelse(NLB_data$Q24 == 4, "High School",
                       ifelse(NLB_data$Q24 == 5, "Bachelors",
                       ifelse(NLB_data$Q24 == 6, "Masters", 
                              NLB_data$Q24)))
NLB_Education$D <-ifelse(test = NLB_Education$D == 1,
                              yes = NA,
                              no = NLB_Education$D)

NLB_Education$D <-ifelse(test = NLB_Education$D == 2,
                              yes = NA,
                              no = NLB_Education$D)

NLB_Education$D <-ifelse(test = NLB_Education$D == 3,
                              yes = NA,
                              no = NLB_Education$D)

NLB_Education$D <-ifelse(test = NLB_Education$D == 7,
                              yes = NA,
                              no = NLB_Education$D)
library(tidyr)
NLB_Education <- drop_na(NLB_Education)
chi_square <- chisq.test(NLB_Education$Group, as.factor(NLB_Education$D))
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_Education$Group and as.factor(NLB_Education$D)
## X-squared = 5.3794, df = 6, p-value = 0.4962

Income

NLB_data$IncomeD <- ifelse(NLB_data$Q26 > 1, "above_500", "Below_500")
chi_square <- chisq.test(NLB_data$IncomeD, as.factor(NLB_data$Group))
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_data$IncomeD and as.factor(NLB_data$Group)
## X-squared = 4.7139, df = 3, p-value = 0.194

Banks

NLB_data$BanksD <- ifelse(NLB_data$Q27 == 1, "NLB", NLB_data$Q27)
NLB_data$BanksD <- ifelse(NLB_data$Q27 == 2, "OTP", "other")
chi_square <- chisq.test(NLB_data$BanksD, as.factor(NLB_data$Group))
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_data$BanksD and as.factor(NLB_data$Group)
## X-squared = 0.26141, df = 3, p-value = 0.9671

Q6 - Which of the following sources of income do you have and how do you receive them?

library(dplyr)

NLB_Q6 <- NLB_data %>%
  filter(!(Q6a %in% c("NA", "Don't want to answer"))) %>%
  select(Q6a, Group)
chi_square <- chisq.test(NLB_Q6$Q6a, as.factor(NLB_Q6$Group))
## Warning in chisq.test(NLB_Q6$Q6a, as.factor(NLB_Q6$Group)): Chi-squared
## approximation may be incorrect
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_Q6$Q6a and as.factor(NLB_Q6$Group)
## X-squared = 11.986, df = 9, p-value = 0.2141

Gender

NLB_data <- NLB_data %>%
  mutate(across(c(Q23), ~ as.numeric(as.character(.))))
# Shapiro-Wilk Test for normality within each group
shapiro_results <- NLB_data %>%
  group_by(Group) %>%
  summarise(p_value = shapiro.test(Q23)$p.value)

print(shapiro_results)
## # A tibble: 4 × 2
##   Group  p_value
##   <int>    <dbl>
## 1     1 7.65e-11
## 2     2 2.40e-13
## 3     3 7.43e-15
## 4     4 1.94e- 9
# Levene's Test for homogeneity of variances

NLB_data$Group <- as.factor(NLB_data$Group)

library(car)
## Loading required package: carData
## 
## Attaching package: 'car'
## The following object is masked from 'package:dplyr':
## 
##     recode
levene_test_result <- leveneTest(Q23 ~ Group, data = NLB_data)

print(levene_test_result)
## Levene's Test for Homogeneity of Variance (center = median)
##        Df F value Pr(>F)
## group   3  0.3586 0.7829
##       300
# Kruskal-Wallis test
kruskal_test_result <- kruskal.test(Q23 ~ Group, data = NLB_data)

# View the result
kruskal_test_result
## 
##  Kruskal-Wallis rank sum test
## 
## data:  Q23 by Group
## Kruskal-Wallis chi-squared = 1.5054, df = 3, p-value = 0.681

SUCCESFULL Criterion valdity

Q3c - How many times a month do you use mobile payments on average?

NLB_data$Q3c_merged <- ifelse(NLB_data$Q3c == 1, "never",
                        ifelse(NLB_data$Q3c %in% c(2, 3), "irregular basis", "regular basis"))
chi_square <- chisq.test(NLB_data$Q3c_merged, as.factor(NLB_data$Group))
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_data$Q3c_merged and as.factor(NLB_data$Group)
## X-squared = 19.394, df = 6, p-value = 0.003547

Mobile Payment usage

# Calculate frequency by Response
Phone_freq <- NLB_data %>%
  group_by(Group, Q3c_merged) %>%
  summarise(Count = n(), .groups = 'drop') %>% 
  group_by(Group) %>%
  mutate(Percentage = Count / sum(Count) * 100)

# Plot the frequency by Response
ggplot(Phone_freq, aes(x = Group, y = Percentage, fill = Q3c_merged)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Response",
    x = "Group",
    y = "Percentage(%)",
    fill = "Mobile Payment Usage"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

Q4 - How often do I use cash for purchases up to 10 EUR?

NLB_data$Q4a_merged <- ifelse(NLB_data$Q4a %in% c(1, 2), "less than half",
                        ifelse(NLB_data$Q4a %in% 3, "half", "more than half"))
chi_square <- chisq.test(NLB_data$Q4a_merged, as.factor(NLB_data$Group))
chi_square
## 
##  Pearson's Chi-squared test
## 
## data:  NLB_data$Q4a_merged and as.factor(NLB_data$Group)
## X-squared = 20.107, df = 6, p-value = 0.00265

cash usage for purchases up to 10 EUR

# Calculate frequency by Response
Purchases_freq <- NLB_data %>%
  group_by(Group, Q4a_merged) %>%
  summarise(Count = n(), .groups = 'drop') %>%
  group_by(Group) %>%
  mutate(Percentage = Count / sum(Count) * 100)

# Plot the frequency by Response
ggplot(Purchases_freq, aes(x = Group, y = Percentage, fill = Q4a_merged)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Response",
    x = "Group",
    y = "Percentage(%)",
    fill = "Cash Payment for purchases up to 10 EUR"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

Age

NLB_data <- NLB_data %>%
  mutate(across(c(Q1F), ~ as.numeric(as.character(.))))
class(NLB_data$Q1F)
## [1] "numeric"
# Shapiro-Wilk test for normality within each group
NLB_data %>%
  group_by(Group) %>%
  summarise(p_value = shapiro.test(Q1F)$p.value)
## # A tibble: 4 × 2
##   Group p_value
##   <fct>   <dbl>
## 1 1     0.0750 
## 2 2     0.00322
## 3 3     0.00231
## 4 4     0.0190
NLB_data$Group <- as.factor(NLB_data$Group)

library(car)
leveneTest(Q1F ~ Group, data = NLB_data)
## Levene's Test for Homogeneity of Variance (center = median)
##        Df F value Pr(>F)  
## group   3  2.1509 0.0939 .
##       300                 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
kruskal_test <- kruskal.test(Q1F ~ Group, data = NLB_data)
print(kruskal_test)
## 
##  Kruskal-Wallis rank sum test
## 
## data:  Q1F by Group
## Kruskal-Wallis chi-squared = 6.8551, df = 3, p-value = 0.07666
group_count <- table(NLB_data$Q1F, NLB_data$Group)
print(group_count)
##     
##       1  2  3  4
##   18  3  1  5  6
##   19  2  7 10  2
##   20  9  8 13 10
##   21  6  8  8  1
##   22  8 14 14  8
##   23 15 23 16 10
##   24  9  8 11  2
##   25  6 19 14  4
##   26  4  2  5  2
##   27  1  3  7  0
# Calculate percentage by Group
Bank_freq <- NLB_data %>%
  group_by(Group, Q1F) %>%
  summarise(Count = n(), .groups = 'drop') %>%
  group_by(Group) %>%
  mutate(Percentage = Count / sum(Count) * 100)

# Plot the percentage by Response
ggplot(Bank_freq, aes(x = Group, y = Percentage, fill = as.factor(Q1F))) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Percentage Distribution of Age by Group",
    x = "Group",
    y = "Percentage (%)",
    fill = "Age"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

Bank

NLB_data <- NLB_data %>%
  mutate(across(c(Q27), ~ as.numeric(as.character(.))))
# Shapiro-Wilk Test for normality within each group
shapiro_results <- NLB_data %>%
  group_by(Group) %>%
  summarise(p_value = shapiro.test(Q27)$p.value)

print(shapiro_results)
## # A tibble: 4 × 2
##   Group  p_value
##   <fct>    <dbl>
## 1 1     2.23e-10
## 2 2     4.69e-11
## 3 3     4.26e-14
## 4 4     7.67e- 8
# Levene's Test for homogeneity of variances
library(car)
levene_test_result <- leveneTest(Q27 ~ Group, data = NLB_data)

print(levene_test_result)
## Levene's Test for Homogeneity of Variance (center = median)
##        Df F value Pr(>F)
## group   3  0.6694 0.5714
##       300
# Kruskal-Wallis test
kruskal_test_result <- kruskal.test(Q27 ~ Group, data = NLB_data)

# View the result
kruskal_test_result
## 
##  Kruskal-Wallis rank sum test
## 
## data:  Q27 by Group
## Kruskal-Wallis chi-squared = 8.1385, df = 3, p-value = 0.04323
# Calculate frequency by Response
Bank_freq <- NLB_data %>%
  group_by(Group, Q27F) %>%
  summarise(Count = n(), .groups = 'drop') %>%
  group_by(Group) %>%
  mutate(Percentage = Count / sum(Count) * 100)

# Plot the frequency by Response
ggplot(Bank_freq, aes(x = Group, y = Percentage, fill = Q27F)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Response",
    x = "Group",
    y = "Percentage(%)",
    fill = "Bank"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

Graphs - demographics

Income

# Calculate frequency by Income (Q26F) and Group
income_freq <- NLB_data %>%
  group_by(Group, Q26F) %>%
  summarise(Count = n(), .groups = 'drop')

# Plot the frequency by Income
ggplot(income_freq, aes(x = Q26F, y = Count, fill = Group)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Income",
    x = "Income",
    y = "Frequency",
    fill = "Group"
  ) +
  theme_minimal()

Status

# Calculate frequency by Income (Q25F) and Group
status_freq <- NLB_data %>%
  group_by(Group, Q25F) %>%
  summarise(Count = n(), .groups = 'drop')

# Plot the frequency by status
ggplot(status_freq, aes(x = Q25F, y = Count, fill = Group)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Status",
    x = "Status",
    y = "Frequency",
    fill = "Group"
  ) +
  theme_minimal()

Education

# Calculate frequency by Education (Q24F) and Group
education_freq <- NLB_data %>%
  group_by(Group, Q24F) %>%
  summarise(Count = n(), .groups = 'drop')

# Plot the frequency by Education
ggplot(education_freq, aes(x = Q24F, y = Count, fill = Group)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Education",
    x = "Education",
    y = "Frequency",
    fill = "Group"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

Response

# Calculate frequency by Response
response_freq <- NLB_data %>%
  group_by(Group, Q5F) %>%
  summarise(Count = n(), .groups = 'drop')

# Plot the frequency by Response
ggplot(response_freq, aes(x = Q5F, y = Count, fill = Group)) +
  geom_bar(stat = "identity", position = "dodge") +
  labs(
    title = "Frequency by Response",
    x = "Response",
    y = "Frequency",
    fill = "Group"
  ) +
  theme_minimal() +
  theme(axis.text.x = element_text(angle = 45, hjust = 1))  # Rotate x-axis labels if needed

PCA Analysis - creaing a perception map

NLB_PCA <- NLB_data[ , c("Q10a", "Q10b", "Q10c", "Q10d", "Q10e", "Q11a", "Q11b", "Q11c", "Q11d", "Q11e", "Q12a", "Q12b", "Q12c", "Q12d", "Q12e", "Q13a", "Q13b", "Q13c", "Q13d", "Q13e", "Q14a", "Q14b", "Q14c", "Q14d", "Q14e", "Q15a", "Q15b", "Q15c", "Q15d", "Q15e")]

library(pastecs)
library(dplyr)

NLB_PCA <- NLB_PCA %>%
  rename(
    Cash_Security = Q10a,
    Debit_Security = Q10b,
    Credit_Security = Q10c,
    Mobile_Security = Q10d,
    NeoBanks_Security = Q10e,
    
    Cash_Ease = Q11a,
    Debit_Ease = Q11b,
    Credit_Ease = Q11c,
    Mobile_Ease = Q11d,
    NeoBanks_Ease = Q11e,
    
    Cash_Availability = Q12a,
    Debit_Availability = Q12b,
    Credit_Availability = Q12c,
    Mobile_Availability = Q12d,
    NeoBanks_Availability = Q12e,
    
    Cash_Speed = Q13a,
    Debit_Speed = Q13b,
    Credit_Speed = Q13c,
    Mobile_Speed = Q13d,
    NeoBanks_Speed = Q13e,
    
    Cash_Privacy = Q14a,
    Debit_Privacy = Q14b,
    Credit_Privacy = Q14c,
    Mobile_Privacy = Q14d,
    NeoBanks_Privacy = Q14e,
    
    Cash_Control = Q15a,
    Debit_Control = Q15b,
    Credit_Control = Q15c,
    Mobile_Control = Q15d,
    NeoBanks_Control = Q15e)
library(tibble)
perceptual <- NLB_PCA %>% 
  pivot_longer(everything(), names_to = "name", values_to = "score")  %>% 
  separate(name, into = c("Payment method", "Variable"), sep = "_")%>% 
  pivot_wider(names_from = Variable, values_from = score, values_fn = mean) %>%
  column_to_rownames(var = "Payment method")

print(perceptual)
##          Security     Ease Availability    Speed  Privacy  Control
## Cash     5.503289 5.101974     6.226974 4.075658 5.680921 4.851974
## Debit    5.138158 6.148026     6.483553 6.174342 4.457237 5.154605
## Credit   4.947368 6.019737     6.335526 6.121711 4.457237 5.006579
## Mobile   5.174342 6.480263     6.029605 6.526316 4.394737 5.161184
## NeoBanks 4.825658 5.592105     5.075658 5.684211 4.483553 5.115132
library(FactoMineR)
pca <- PCA(perceptual, 
           scale.unit = TRUE, 
           graph = FALSE,
           ncp = 2)
print(pca$var$cor)
##                   Dim.1        Dim.2
## Security     -0.7563320  0.534605714
## Ease          0.8659604  0.465478553
## Availability -0.1808968  0.942766082
## Speed         0.9753947  0.204881709
## Privacy      -0.9934258  0.026725632
## Control       0.9275822 -0.001610424
library(factoextra)
fviz_pca_biplot(pca, 
                repel = TRUE)