Skip to content
Snippets Groups Projects
Commit 4847fac6 authored by nc71qaxa's avatar nc71qaxa
Browse files

sociodemo_table

parent a14f0e0e
Branches
No related tags found
No related merge requests found
...@@ -59,25 +59,25 @@ print(xtable(treatment_socio_B, type ="latex"), ...@@ -59,25 +59,25 @@ print(xtable(treatment_socio_B, type ="latex"),
include.rownames = F, file ="Tables/socio_demos_B.tex") include.rownames = F, file ="Tables/socio_demos_B.tex")
### Case C ### Case C
treatment_socio <- database_full %>% filter(!is.na(Treatment)) %>% group_by(Treatment) %>% treatment_socio <- database_full %>% filter(!is.na(Treatment)) %>% group_by(Treatment_C) %>%
summarize_at(c('Gender_female', 'Uni_degree', 'Age', 'HHSize', "Rent_SQ", "Kids_Dummy", "WalkingDistance_SQ", summarize_at(c('Gender_female', 'Uni_degree', 'Age', 'HHSize', "Rent_SQ", "Kids_Dummy", "WalkingDistance_SQ",
"Naturalness_SQ", "Employment_full", "Z_Mean_NR"), "Naturalness_SQ", "Employment_full", "Z_Mean_NR"),
~ round(mean(., na.rm = TRUE), 2)) ~ round(mean(., na.rm = TRUE), 2))
treatment_socio_C <- database_full %>% filter(!is.na(Treatment_new)) %>% group_by(Treatment_new) %>% treatment_socio_C <- database_full %>% filter(!is.na(Treatment_new)) %>% group_by(Treatment_C) %>%
summarize_at(c('Gender_female', 'Uni_degree', 'Age', 'HHSize', "Rent_SQ", "Kids_Dummy", "WalkingDistance_SQ", summarize_at(c('Gender_female', 'Uni_degree', 'Age', 'HHSize', "Rent_SQ", "Kids_Dummy", "WalkingDistance_SQ",
"Naturalness_SQ", "Employment_full", "Pensioner"), "Naturalness_SQ", "Employment_full", "Z_Mean_NR"),
~ round(mean(., na.rm = TRUE), 2)) ~ round(mean(., na.rm = TRUE), 2))
#
treatment_socio_C <- treatment_socio_C %>% mutate(Treatment_name = case_when( # treatment_socio_C <- treatment_socio_C %>% mutate(Treatment_name = case_when(
Treatment_new == 1 ~ 'Video 1', # Treatment_new == 1 ~ 'Video 1',
Treatment_new == 2 ~ 'No Video 1', # Treatment_new == 2 ~ 'No Video 1',
Treatment_new == 3 ~ 'No Info 2', # Treatment_new == 3 ~ 'No Info 2',
Treatment_new == 4 ~ 'No Video 2', # Treatment_new == 4 ~ 'No Video 2',
Treatment_new == 5 ~ 'Video 2', # Treatment_new == 5 ~ 'Video 2',
Treatment_new == 6 ~ 'No Treatment 3', # Treatment_new == 6 ~ 'No Treatment 3',
TRUE ~ NA_character_ # TRUE ~ NA_character_
)) # ))
# Export table as tex file # Export table as tex file
print(xtable(treatment_socio_C, type ="latex"), print(xtable(treatment_socio_C, type ="latex"),
......
...@@ -118,26 +118,24 @@ list_ols <- list("(Intercept)" = "Intercept", "as.factor(Treatment_A)Treated" = ...@@ -118,26 +118,24 @@ list_ols <- list("(Intercept)" = "Intercept", "as.factor(Treatment_A)Treated" =
``` ```
## Socio Demografics {.smaller} ## Socio Demografics {.smaller}
::: {style="font-size: 37%;"} ::: {style="font-size: 50%;"}
::: panel-tabset ::: panel-tabset
### Case A ### Case A
```{r} ```{r}
library(DT) kableExtra::kable(treatment_socio_A)
treatment_socio_A <- treatment_socio_A
datatable(treatment_socio_A)
``` ```
### Case C ### Case C
```{r} ```{r}
library(DT) kableExtra::kable(treatment_socio_C)
treatment_socio_C <- treatment_socio_C %>% select(-Treatment_new) %>% select(Treatment_name, everything())
datatable(treatment_socio_C)
``` ```
::: :::
::: :::
## NR ## NR
**Hypotheses:** Individuals with greater Nature Relatedness (NR) are more inclined to autonomously seek information about environmental subjects, such as the impact of urban green spaces on urban heat islands. Consequently, any observed increase in the willingness to pay among the treated group may be attributed to the individuals' higher NR rather than the treatment itself. **Hypotheses:** Individuals with greater Nature Relatedness (NR) are more inclined to autonomously seek information about environmental subjects, such as the impact of urban green spaces on urban heat islands. Consequently, any observed increase in the willingness to pay among the treated group may be attributed to the individuals' higher NR rather than the treatment itself.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment