Skip to content
Snippets Groups Projects
Commit ef9cef85 authored by Daniel.Kalioudjoglou's avatar Daniel.Kalioudjoglou
Browse files

remplacer na par nc dans tableau

parent 3cc9b3a7
No related branches found
No related tags found
1 merge request!25remplacer na par nc dans tableau
Pipeline #236826 failed
......@@ -35,6 +35,7 @@ creer_tableau_synthese_annuel <- function(data = indic_ecln,
"PrixM2 - Appartements"
)
}
input <- indic_ecln %>%
dplyr::filter(
.data$Indicateur %in% indic,
......@@ -71,7 +72,7 @@ creer_tableau_synthese_annuel <- function(data = indic_ecln,
kableExtra::row_spec(1:2, bold = T, background = "#f0f0f5") %>%
kableExtra::add_header_above(c(" " = 1, "Ventes" = 2, "Mises en vente" = 2, "Encours" = 2, "Prix au m2" = 2)) %>%
kableExtra::add_indent(c(3:nombre_zone)) %>%
kableExtra::footnote(general_title="",general = "NA : donn\u00e9es non communiqu\u00e9es (secret statistique)")
kableExtra::footnote(general_title="",general = "NC : donn\u00e9es non communiqu\u00e9es (secret statistique)")
if ("ABC" %in% type_zone) {
res <- res %>%
kableExtra::row_spec(nombre_fr_dep_reg:nombre_zone, bold = T, background = "#bebece")
......
......@@ -34,6 +34,7 @@ creer_tableau_synthese_trimestrielle <- function(data = indic_ecln,
"PrixM2 - Appartements"
)
}
indic_ecln %>%
dplyr::filter(
.data$Indicateur %in% indic,
......@@ -58,7 +59,7 @@ creer_tableau_synthese_trimestrielle <- function(data = indic_ecln,
by = c("TypeZone", "Zone")
) %>%
dplyr::arrange(.data$Zone) %>%
dplyr::select(2, 6, 10, 4, 8, 3, 7, 5, 9) %>%
dplyr::select(2, 6, 10, 4, 8, 3, 7, 5, 9)%>%
knitr::kable("html",
col.names = c(
"Zone", "Sur le dernier trimestre", "Evolution sur un an (en %)",
......@@ -72,6 +73,6 @@ creer_tableau_synthese_trimestrielle <- function(data = indic_ecln,
kableExtra::kable_styling(font_size = 12) %>%
kableExtra::row_spec(1:2, bold = T, background = "#f0f0f5") %>%
kableExtra::add_header_above(c(" " = 1, "Ventes" = 2, "Mises en vente" = 2, "Encours" = 2, "Prix au m2" = 2)) %>%
kableExtra::footnote(general_title="",general = "NA : donn\u00e9es non communiqu\u00e9es (secret statistique)")
kableExtra::footnote(general_title="",general = "NC : donn\u00e9es non communiqu\u00e9es (secret statistique)")
}
......@@ -99,12 +99,14 @@ A COMPLETER
#### Chiffres trimestriels
```{r logementstableautrim}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_trimestrielle(type_logement = "logement")
```
#### Chiffres cumulés sur les 4 derniers trimestres
```{r logementstableaucumul}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_annuel(
type_logement = "logement",
type_zone = typezone
......@@ -213,12 +215,14 @@ A COMPLETER
#### Chiffres trimestriels
```{r collectiftableautrim}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_trimestrielle(type_logement = "collectif")
```
#### Chiffres cumulés sur les 4 derniers trimestres
```{r collectiftableaucumul}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_annuel(
type_logement = "collectif",
type_zone = typezone
......@@ -329,12 +333,14 @@ A COMPLETER
#### Chiffres trimestriels
```{r individueltableautrim}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_trimestrielle(type_logement = "individuel")
```
#### Chiffres cumulés sur les 4 derniers trimestres
```{r individueltableaucumul}
opts <- options(knitr.kable.NA = "NC")
creer_tableau_synthese_annuel(
type_logement = "individuel",
type_zone = typezone
......
......@@ -6,7 +6,7 @@
\alias{indic_ecln}
\title{Table contenant les différents indicateurs de la source ecln utiles pour la publication.}
\format{
Table de 2197156 lignes et 9 colonnes:
Table de 96720 lignes et 10 colonnes:
\describe{
\item{TypeZone}{Type de territoire}
\item{CodeZone}{Code du territoire}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment