---
title: "Faktorska analiza"
output: 
  flexdashboard::flex_dashboard:
    social: menu
    orientation: columns
    vertical_layout: fill
    source_code: embed
---

```{css, echo=FALSE}
.sidebar { overflow: auto; }
.dataTables_scrollBody {
    height:95% !important;
    max-height:95% !important;
}
.chart-stage-flex {
    overflow:auto !important;
}
```

```{r setup, include=FALSE}
library(DT)
library(knitr)
library(kableExtra)
library(psych)
library(car)
library(readxl)
library(tidyverse)
library(corrplot)
library(svgPanZoom)
library(lavaan)
library(parameters)

cols <- c("osoba", "DYNAMICS", "AVERAGE_COMPARISON", "REQUESTS", "MESSAGES_SU",
          "EXTRACURRICULAR", "STATUS_COMPARISON", "PREDICTION_GROUP", "TEACHERS", "BADGES", 
          "PREDICTION_OBLIGATIONS", "ABSENCE", "STATUS_CURRENT", "ASSESSMENT_EXAMS")
podaci_EFA <- read_excel('potrebe_studenata_2017.xlsx', sheet=1) %>% select(-one_of(cols))
new_cols <- c("osoba")
podaci_CFA <- read_excel('potrebe_studenata_2022.xlsx', sheet=1) %>% select(-one_of(new_cols))
EFA_model <- fa(podaci_EFA, nfactors = 5)
file.name <- './graf4.svg'
in.svg <- readChar(file.name, nchars = file.info(file.name)$size)

podaci_sve <- bind_rows("2017" = podaci_EFA, "2022" = podaci_CFA, .id = "GODINA") %>% 
  select_if(~ !any(is.na(.)))
podaci_sve$GODINA <- factor(podaci_sve$GODINA)

model1 <- efa_to_cfa(EFA_model, threshold = 0.6)
rez1 <- cfa(model1, podaci_CFA)
```

Deskriptiva {data-navmenu="Podaci"}
=======================================================================

Column {.tabset .tabset-fade}
-----------------------------------------------------------------------

### Godina 2017.

```{r}
datatable(round(describe(podaci_EFA),2), filter = 'top',
    extensions = c('FixedColumns','Select', 'Buttons'),
    options = list(
      dom = 'Blfrtip',
      select = list(style = 'os', items = 'row'),
      buttons = c('selectAll', 'selectNone', 'selectRows', 'selectColumns', 'selectCells'),
      pageLength = 15,
      scrollX = TRUE,
      scrollY= TRUE,
      fixedColumns = TRUE
    )
)
```

### Godina 2022.

```{r}
datatable(round(describe(podaci_CFA),2), filter = 'top',
    extensions = c('FixedColumns','Select', 'Buttons'),
    options = list(
      dom = 'Blfrtip',
      select = list(style = 'os', items = 'row'),
      buttons = c('selectAll', 'selectNone', 'selectRows', 'selectColumns', 'selectCells'),
      pageLength = 15,
      scrollX = TRUE,
      scrollY= TRUE,
      fixedColumns = TRUE
    )
)
```

Deskriptiva - slike {data-navmenu="Podaci"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Godina 2017.

```{r,fig.width = 12,fig.height=11}
error.dots(podaci_EFA, tail=30, head=30, sort=FALSE)
```

Column {data-width=400}
-----------------------------------------------------------------------

### Godina 2022.

```{r,fig.width = 12,fig.height=11}
error.dots(podaci_CFA, tail=30, head=30, sort=FALSE)
```

Korelacije {data-navmenu="Podaci"}
=======================================================================

Column {.tabset .tabset-fade}
-----------------------------------------------------------------------

### Godina 2017.

```{r}
datatable(round(corr.test(podaci_EFA, use = "pairwise.complete.obs", minlength=50)$ci, 2), filter = 'top',
    extensions = c('FixedColumns','Select', 'Buttons'),
    options = list(
      dom = 'Blfrtip',
      select = list(style = 'os', items = 'row'),
      buttons = c('selectAll', 'selectNone', 'selectRows', 'selectColumns', 'selectCells'),
      pageLength = 15,
      scrollX = TRUE,
      fixedColumns = TRUE
    )
)
```

### Godina 2022.

```{r}
datatable(round(corr.test(podaci_CFA, use = "pairwise.complete.obs", minlength=50)$ci, 2), filter = 'top',
    extensions = c('FixedColumns','Select', 'Buttons'),
    options = list(
      dom = 'Blfrtip',
      select = list(style = 'os', items = 'row'),
      buttons = c('selectAll', 'selectNone', 'selectRows', 'selectColumns', 'selectCells'),
      pageLength = 15,
      scrollX = TRUE,
      fixedColumns = TRUE
    )
)
```


Korelacije - slike {data-navmenu="Podaci"}
=======================================================================

## Column1 {.tabset .tabset-fade}

### korelacije 2017.

```{r}
corrplot(round(cor(podaci_EFA, use = "pairwise.complete.obs"), 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### p-vrijednosti 2017.

```{r}
corrplot(round(corr.test(podaci_EFA, use = "pairwise.complete.obs")$p, 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### korelacije 2022.

```{r}
corrplot(round(cor(podaci_CFA, use = "pairwise.complete.obs"), 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### p-vrijednosti 2022.

```{r}
corrplot(round(corr.test(podaci_CFA, use = "pairwise.complete.obs")$p, 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

## Column1 {.tabset .tabset-fade}

### korelacije 2022.

```{r}
corrplot(round(cor(podaci_CFA, use = "pairwise.complete.obs"), 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### p-vrijednosti 2022.

```{r}
corrplot(round(corr.test(podaci_CFA, use = "pairwise.complete.obs")$p, 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### korelacije 2017.

```{r}
corrplot(round(cor(podaci_EFA, use = "pairwise.complete.obs"), 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

### p-vrijednosti 2017.

```{r}
corrplot(round(corr.test(podaci_EFA, use = "pairwise.complete.obs")$p, 2), type = "upper", tl.col = "black", tl.srt = 90,
         diag=FALSE, mar=c(0,0,0.1,0), tl.cex=0.4)
```

Unutarnja pouzdanost {data-navmenu="EFA 2017"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Cronbach alpha

```{r, attr.output='style="max-height: 100%;"'}
psych::alpha(podaci_EFA)
```

Column {data-width=400}
-----------------------------------------------------------------------

### split-half


```{r, attr.output='style="max-height: 100%;"'}
splitHalf(podaci_EFA)
```

### Kaiser-Meyer-Olkin

```{r, attr.output='style="max-height: 100%;"'}
KMO(podaci_EFA)
```

EFA - broj faktora {data-navmenu="EFA 2017"}
=======================================================================

Column {data-width=300}
-----------------------------------------------------------------------

### Svojstvene vrijednosti matrice korelacija

```{r warning=FALSE}
EFA_cor <- cor(podaci_EFA, use = "pairwise.complete.obs")
sv <- eigen(EFA_cor)
sv$values
```

Column {data-width=500}
-----------------------------------------------------------------------

### SCREE plot

```{r warning=FALSE,fig.width=8, fig.height=7}
scree(podaci_EFA)
```

EFA model {data-navmenu="EFA 2017"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### EFA - 5 faktora

```{r, attr.output='style="max-height: 100%;"'}
EFA_model
```

Column {data-width=400}
-----------------------------------------------------------------------

### Loadings (cutoff = 0.6)

```{r, attr.output='style="max-height: 100%;"'}
print(EFA_model$loadings, sort=TRUE, cutoff=0.6)
```

Loadings {data-navmenu="EFA 2017"}
=======================================================================

Column {.tabset .tabset-fade}
-----------------------------------------------------------------------

### Interaktivna tablica

```{r}
datatable(round(unclass(EFA_model$loadings),2), filter = 'top',
    extensions = c('FixedColumns','Select', 'Buttons'),
    options = list(
      dom = 'Blfrtip',
      select = list(style = 'os', items = 'row'),
      buttons = c('selectAll', 'selectNone', 'selectRows', 'selectColumns', 'selectCells'),
      pageLength = 15,
      scrollX = TRUE,
      fixedColumns = TRUE
    )
)
```

### graf

```{r}
svgPanZoom(in.svg, controlIconsEnabled = TRUE)
```

Scores {data-navmenu="EFA 2017"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Funkcija gustoće

```{r warning=FALSE}
plot(density(EFA_model$scores, na.rm = TRUE), 
    main = "Factor Scores")
```

Column {data-width=400}
-----------------------------------------------------------------------

### tablica

```{r,attr.output='style="max-height: 100%;"'}
EFA_model$scores
```

Summary {data-navmenu="CFA 2022"}
=======================================================================

Column {.tabset .tabset-fade}
-----------------------------------------------------------------------

### Model (cutoff=0.6)

```{r}
model1
```

### Summary (cutoff=0.6)

```{r}
summary(rez1, fit.measures=TRUE)
```

### Sve mjere testa (cutoff=0.6)

```{r}
fitMeasures(rez1)
```

Parametri {data-navmenu="CFA 2022"}
=======================================================================

### Parametri (cutoff=0.6)

```{r}
parameterEstimates(rez1) %>%
  kbl(caption = "Parametri (cutoff=0.4)") %>%
  kable_classic("hover",full_width = F, html_font = "Cambria")
```

Normalizirani parametri {data-navmenu="CFA 2022"}
=======================================================================

### Normalizirani parametri (cutoff=0.6)

```{r}
standardizedSolution(rez1) %>%
  kbl(caption = "Normalizirani parametri (cutoff=0.4)") %>%
  kable_classic("hover",full_width = F, html_font = "Cambria")
```

TIMELINE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(TIMELINE))
leveneTest(TIMELINE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(TIMELINE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(TIMELINE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(TIMELINE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(TIMELINE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

RISK {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(RISK))
leveneTest(RISK ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(RISK, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(RISK ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(RISK ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(RISK ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

AVERAGE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(AVERAGE))
leveneTest(AVERAGE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(AVERAGE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(AVERAGE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(AVERAGE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(AVERAGE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

SCHEDULE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(SCHEDULE))
leveneTest(SCHEDULE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(SCHEDULE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(SCHEDULE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(SCHEDULE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(SCHEDULE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

CALENDAR {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(CALENDAR))
leveneTest(CALENDAR ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(CALENDAR, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(CALENDAR ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(CALENDAR ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(CALENDAR ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COURSES {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COURSES))
leveneTest(COURSES ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COURSES, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COURSES ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COURSES ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COURSES ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

NOTIFICATIONS_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(NOTIFICATIONS_COURSE))
leveneTest(NOTIFICATIONS_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(NOTIFICATIONS_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(NOTIFICATIONS_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(NOTIFICATIONS_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(NOTIFICATIONS_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

NOTIFICATIONS_DEADLINES {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(NOTIFICATIONS_DEADLINES))
leveneTest(NOTIFICATIONS_DEADLINES ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(NOTIFICATIONS_DEADLINES, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(NOTIFICATIONS_DEADLINES ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(NOTIFICATIONS_DEADLINES ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(NOTIFICATIONS_DEADLINES ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

MESSAGES_TEACHER {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(MESSAGES_TEACHER))
leveneTest(MESSAGES_TEACHER ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(MESSAGES_TEACHER, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(MESSAGES_TEACHER ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(MESSAGES_TEACHER ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(MESSAGES_TEACHER ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

MESSAGES_ADMIN {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(MESSAGES_ADMIN))
leveneTest(MESSAGES_ADMIN ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(MESSAGES_ADMIN, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(MESSAGES_ADMIN ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(MESSAGES_ADMIN ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(MESSAGES_ADMIN ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPARISON_EXAMS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPARISON_EXAMS))
leveneTest(COMPARISON_EXAMS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPARISON_EXAMS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPARISON_EXAMS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPARISON_EXAMS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPARISON_EXAMS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPARISON_ECTS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPARISON_ECTS))
leveneTest(COMPARISON_ECTS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPARISON_ECTS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPARISON_ECTS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPARISON_ECTS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPARISON_ECTS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPARISON_GRADES {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPARISON_GRADES))
leveneTest(COMPARISON_GRADES ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPARISON_GRADES, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPARISON_GRADES ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPARISON_GRADES ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPARISON_GRADES ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPARISON_OBLIGATIONS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPARISON_OBLIGATIONS))
leveneTest(COMPARISON_OBLIGATIONS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPARISON_OBLIGATIONS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPARISON_OBLIGATIONS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPARISON_OBLIGATIONS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPARISON_OBLIGATIONS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

STATUS_STUDENTS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(STATUS_STUDENTS))
leveneTest(STATUS_STUDENTS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(STATUS_STUDENTS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(STATUS_STUDENTS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(STATUS_STUDENTS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(STATUS_STUDENTS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PREDICTION_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PREDICTION_COURSE))
leveneTest(PREDICTION_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PREDICTION_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PREDICTION_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PREDICTION_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PREDICTION_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PREDICTION_YEAR {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PREDICTION_YEAR))
leveneTest(PREDICTION_YEAR ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PREDICTION_YEAR, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PREDICTION_YEAR ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PREDICTION_YEAR ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PREDICTION_YEAR ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PREDICTION_ECTS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PREDICTION_ECTS))
leveneTest(PREDICTION_ECTS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PREDICTION_ECTS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PREDICTION_ECTS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PREDICTION_ECTS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PREDICTION_ECTS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PREDICTION_PROGRAM {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PREDICTION_PROGRAM))
leveneTest(PREDICTION_PROGRAM ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PREDICTION_PROGRAM, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PREDICTION_PROGRAM ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PREDICTION_PROGRAM ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PREDICTION_PROGRAM ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

ECTSAVG_STUDY {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(ECTSAVG_STUDY))
leveneTest(ECTSAVG_STUDY ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(ECTSAVG_STUDY, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(ECTSAVG_STUDY ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(ECTSAVG_STUDY ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(ECTSAVG_STUDY ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

ECTSAVG_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(ECTSAVG_COURSE))
leveneTest(ECTSAVG_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(ECTSAVG_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(ECTSAVG_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(ECTSAVG_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(ECTSAVG_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

AVGGRADE_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(AVGGRADE_COURSE))
leveneTest(AVGGRADE_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(AVGGRADE_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(AVGGRADE_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(AVGGRADE_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(AVGGRADE_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PASSRATE_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PASSRATE_COURSE))
leveneTest(PASSRATE_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PASSRATE_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PASSRATE_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PASSRATE_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PASSRATE_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PPLAN_COURSE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PPLAN_COURSE))
leveneTest(PPLAN_COURSE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PPLAN_COURSE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PPLAN_COURSE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PPLAN_COURSE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PPLAN_COURSE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PPLAN_STUDY {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PPLAN_STUDY))
leveneTest(PPLAN_STUDY ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PPLAN_STUDY, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PPLAN_STUDY ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PPLAN_STUDY ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PPLAN_STUDY ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PPLAN_MONITORING {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PPLAN_MONITORING))
leveneTest(PPLAN_MONITORING ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PPLAN_MONITORING, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PPLAN_MONITORING ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PPLAN_MONITORING ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PPLAN_MONITORING ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

ECTS_MONITORING {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(ECTS_MONITORING))
leveneTest(ECTS_MONITORING ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(ECTS_MONITORING, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(ECTS_MONITORING ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(ECTS_MONITORING ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(ECTS_MONITORING ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

PPLAN_EXTRACURRICULAR {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(PPLAN_EXTRACURRICULAR))
leveneTest(PPLAN_EXTRACURRICULAR ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(PPLAN_EXTRACURRICULAR, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(PPLAN_EXTRACURRICULAR ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(PPLAN_EXTRACURRICULAR ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(PPLAN_EXTRACURRICULAR ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

TEACHER_EVALUATION {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(TEACHER_EVALUATION))
leveneTest(TEACHER_EVALUATION ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(TEACHER_EVALUATION, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(TEACHER_EVALUATION ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(TEACHER_EVALUATION ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(TEACHER_EVALUATION ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

TEACHER_PROFILE {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(TEACHER_PROFILE))
leveneTest(TEACHER_PROFILE ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(TEACHER_PROFILE, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(TEACHER_PROFILE ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(TEACHER_PROFILE ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(TEACHER_PROFILE ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

TEACHERS_CONTEVAL {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(TEACHERS_CONTEVAL))
leveneTest(TEACHERS_CONTEVAL ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(TEACHERS_CONTEVAL, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(TEACHERS_CONTEVAL ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(TEACHERS_CONTEVAL ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(TEACHERS_CONTEVAL ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

TEACHERS_FEEDBACK {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(TEACHERS_FEEDBACK))
leveneTest(TEACHERS_FEEDBACK ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(TEACHERS_FEEDBACK, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(TEACHERS_FEEDBACK ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(TEACHERS_FEEDBACK ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(TEACHERS_FEEDBACK ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

BADGES_COMPARISON {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(BADGES_COMPARISON))
leveneTest(BADGES_COMPARISON ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(BADGES_COMPARISON, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(BADGES_COMPARISON ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(BADGES_COMPARISON ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(BADGES_COMPARISON ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

BADGES_COLLECTING {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(BADGES_COLLECTING))
leveneTest(BADGES_COLLECTING ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(BADGES_COLLECTING, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(BADGES_COLLECTING ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(BADGES_COLLECTING ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(BADGES_COLLECTING ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

AWARDS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(AWARDS))
leveneTest(AWARDS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(AWARDS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(AWARDS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(AWARDS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(AWARDS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPETITIONS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPETITIONS))
leveneTest(COMPETITIONS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPETITIONS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPETITIONS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPETITIONS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPETITIONS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

ASSESSMENT_CONT {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(ASSESSMENT_CONT))
leveneTest(ASSESSMENT_CONT ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(ASSESSMENT_CONT, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(ASSESSMENT_CONT ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(ASSESSMENT_CONT ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(ASSESSMENT_CONT ~ GODINA, data = podaci_sve, conf.int = TRUE)
```

COMPARISON_OTHERS {data-navmenu="TESTOVI"}
=======================================================================

Column {data-width=400}
-----------------------------------------------------------------------

### Varijance po grupama i Levene test

```{r}
podaci_sve %>% group_by(GODINA) %>% summarize(var(COMPARISON_OTHERS))
leveneTest(COMPARISON_OTHERS ~ GODINA, podaci_sve)
```

### Stupčasti dijagram po godinama

```{r}
ggplot(podaci_sve, aes(COMPARISON_OTHERS, fill=GODINA)) + geom_bar(position = position_dodge2(preserve = "single"))
```

Column {data-width=400}
-----------------------------------------------------------------------

### t-test (uz pretpostavku da su varijance po grupama iste)

```{r}
t.test(COMPARISON_OTHERS ~ GODINA, data = podaci_sve, var.equal = TRUE)
```

### t-test (uz pretpostavku da varijance po grupama nisu iste)

```{r}
t.test(COMPARISON_OTHERS ~ GODINA, data = podaci_sve)
```

### Wilcox test

```{r}
wilcox.test(COMPARISON_OTHERS ~ GODINA, data = podaci_sve, conf.int = TRUE)
```


