Code
-= pd.read_csv("02-data/supplementary/terms_inequality.csv")
+ terms_inequality = pd.read_csv("data/supplementary/terms_inequality.csv")
terms_inequality ""), showindex=False, headers="keys", tablefmt="grid")) md(tabulate(terms_inequality.fillna(
@@ -5759,7 +5759,7 @@ Table 4: Inequality term cluster
An overview of the respective criteria used for inclusion or exclusion can be found in Table 5. It restricts studies to those that comprise primary research published after 2000, with a focus on the narrowing criteria specified in Table 5.
Code
-= pd.read_csv("02-data/supplementary/inclusion-criteria.tsv", sep="\t")
+ inclusion_criteria = pd.read_csv("data/supplementary/inclusion-criteria.tsv", sep="\t")
inclusion_criteria =False, headers="keys", tablefmt="grid")) md(tabulate(inclusion_criteria, showindex
@@ -9294,7 +9294,7 @@ Figure 4: Available studies by primary type of intervention
def strength_for(val):
return list(study_strength_bins.keys())[list(study_strength_bins.values()).index(val)]
-= pd.read_csv("02-data/supplementary/findings-institutional.csv")
+ findings_institutional = pd.read_csv("data/supplementary/findings-institutional.csv")
findings_institutional = validity.add_to_findings(findings_institutional, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid")) md(tabulate(fd_df[[
@@ -9558,7 +9558,7 @@ Table 6: Summary of main findings for institutional policies
Code
from src.model import validity
-= pd.read_csv("02-data/supplementary/findings-structural.csv")
+ findings_structural = pd.read_csv("data/supplementary/findings-structural.csv")
findings_structural = validity.add_to_findings(findings_structural, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid")) md(tabulate(fd_df[[
@@ -9794,7 +9794,7 @@ Table 7: Summary of main findings for structural policies
Code
from src.model import validity
-= pd.read_csv("02-data/supplementary/findings-agency.csv")
+ findings_agency = pd.read_csv("data/supplementary/findings-agency.csv")
findings_agency = validity.add_to_findings(findings_agency, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid")) md(tabulate(fd_df[[
@@ -22545,7 +22545,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
"whitegrid")
sns.set_style(
-=Path("./02-data")
+ DATA_DIR=Path("./data")
DATA_DIR=DATA_DIR.joinpath("raw")
RAW_DATA=DATA_DIR.joinpath("intermediate")
WORKING_DATA=DATA_DIR.joinpath("processed")
@@ -22835,7 +22835,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
PROCESSED_DATA```{python}
#| label: tbl-wow-terms
#| tbl-cap: World of work term cluster
-= pd.read_csv("02-data/supplementary/terms_wow.csv")
+ terms_wow = pd.read_csv("data/supplementary/terms_wow.csv")
terms_wow ""), showindex=False, headers="keys", tablefmt="grid"))
md(tabulate(terms_wow.fillna(```
@@ -22857,7 +22857,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
```{python}
#| label: tbl-intervention-terms
#| tbl-cap: Intervention term cluster
-= pd.read_csv("02-data/supplementary/terms_policy.csv")
+ terms_policy = pd.read_csv("data/supplementary/terms_policy.csv")
terms_policy # different headers to include 'social norms'
= ["General", "Institutional", "Structural", "Agency & social norms"]
headers ""), showindex=False, headers=headers, tablefmt="grid"))
@@ -22873,7 +22873,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
md(tabulate(terms_policy.fillna(```{python}
#| label: tbl-inequality-terms
#| tbl-cap: Inequality term cluster
-= pd.read_csv("02-data/supplementary/terms_inequality.csv")
+ terms_inequality = pd.read_csv("data/supplementary/terms_inequality.csv")
terms_inequality ""), showindex=False, headers="keys", tablefmt="grid"))
md(tabulate(terms_inequality.fillna(```
@@ -22897,7 +22897,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
```{python}
#| label: tbl-inclusion-criteria
-= pd.read_csv("02-data/supplementary/inclusion-criteria.tsv", sep="\t")
+ inclusion_criteria = pd.read_csv("data/supplementary/inclusion-criteria.tsv", sep="\t")
inclusion_criteria =False, headers="keys", tablefmt="grid"))
md(tabulate(inclusion_criteria, showindex```
@@ -22948,7 +22948,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
= len([1 for kw in all_keywords if "done::extracted" in kw])
nr_extraction_done
= "`" * 3
- t3 # FIXME use 02-data/supplementary undeduplciated counts to get database starting and snowballing counts
+# FIXME use data/supplementary undeduplciated counts to get database starting and snowballing counts
# from: https://github.com/quarto-dev/quarto-cli/discussions/6508
print(f"""
```{mermaid}
@@ -23145,7 +23145,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
def strength_for(val):
return list(study_strength_bins.keys())[list(study_strength_bins.values()).index(val)]
-= pd.read_csv("02-data/supplementary/findings-institutional.csv")
+ findings_institutional = pd.read_csv("data/supplementary/findings-institutional.csv")
findings_institutional = validity.add_to_findings(findings_institutional, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
@@ -23378,7 +23378,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
md(tabulate(fd_df[[#| label: tbl-findings-structural
from src.model import validity
-= pd.read_csv("02-data/supplementary/findings-structural.csv")
+ findings_structural = pd.read_csv("data/supplementary/findings-structural.csv")
findings_structural = validity.add_to_findings(findings_structural, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
@@ -23615,7 +23615,7 @@ window.document.addEventListener("DOMContentLoaded", function (event) {
md(tabulate(fd_df[[#| label: tbl-findings-agency
from src.model import validity
-= pd.read_csv("02-data/supplementary/findings-agency.csv")
+ findings_agency = pd.read_csv("data/supplementary/findings-agency.csv")
findings_agency = validity.add_to_findings(findings_agency, by_intervention, study_strength_bins)
fd_df
"area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
diff --git a/meeting_eoy.qmd b/meeting_eoy.qmd
index fb6a057..4292023 100644
--- a/meeting_eoy.qmd
+++ b/meeting_eoy.qmd
@@ -1,5 +1,5 @@
---
-bibliography: 02-data/intermediate/zotero-library.bib
+bibliography: data/intermediate/zotero-library.bib
csl: /home/marty/documents/library/utilities/styles/APA-7.csl
papersize: A4
linestretch: 1.5
@@ -30,7 +30,7 @@ import bibtexparser
sns.set_style("whitegrid")
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
PROCESSED_DATA=DATA_DIR.joinpath("processed")
@@ -102,7 +102,7 @@ nr_out_language = len([1 for kw in all_keywords if "out::language" in kw])
nr_extraction_done = len([1 for kw in all_keywords if "done::extracted" in kw])
t3 = "`" * 3
-# FIXME use 02-data/supplementary undeduplciated counts to get database starting and snowballing counts
+# FIXME use data/supplementary undeduplciated counts to get database starting and snowballing counts
# from: https://github.com/quarto-dev/quarto-cli/discussions/6508
print(f"""
```{{mermaid}}
diff --git a/notebooks/bibmanip.qmd b/notebooks/bibmanip.qmd
index e56f2b9..c8a2e23 100644
--- a/notebooks/bibmanip.qmd
+++ b/notebooks/bibmanip.qmd
@@ -1,5 +1,5 @@
---
-bibliography: ../02-data/intermediate/zotero-library.bib
+bibliography: ../data/intermediate/zotero-library.bib
csl: /home/marty/documents/library/utilities/styles/APA-7.csl
papersize: A4
linestretch: 1.5
@@ -22,7 +22,7 @@ subtitle: Addressing inequalities in the World of Work
```{python}
#| echo: false
from pathlib import Path
-data_dir=Path("../02-data")
+data_dir=Path("../data")
## standard imports
from IPython.core.display import Markdown as md
diff --git a/notebooks/explore.qmd b/notebooks/explore.qmd
index 2ae6f92..37c75f6 100644
--- a/notebooks/explore.qmd
+++ b/notebooks/explore.qmd
@@ -1,5 +1,5 @@
---
-bibliography: 02-data/intermediate/zotero-library.bib
+bibliography: data/intermediate/zotero-library.bib
title: Grab yml
---
@@ -187,7 +187,7 @@ import bibtexparser
sns.set_style("whitegrid")
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
PROCESSED_DATA=DATA_DIR.joinpath("processed")
diff --git a/notebooks/main-findings.qmd b/notebooks/main-findings.qmd
index 663c2b2..0996e55 100644
--- a/notebooks/main-findings.qmd
+++ b/notebooks/main-findings.qmd
@@ -15,7 +15,7 @@ import bibtexparser
sns.set_style("whitegrid")
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
PROCESSED_DATA=DATA_DIR.joinpath("processed")
@@ -120,7 +120,7 @@ datavis:
```{python}
-findings_institutional = pd.read_csv("02-data/supplementary/findings-institutional.csv")
+findings_institutional = pd.read_csv("data/supplementary/findings-institutional.csv")
findings_institutional
from src.model import validity
import math
diff --git a/notebooks/rank_validities.qmd b/notebooks/rank_validities.qmd
index 2544a94..10d5907 100644
--- a/notebooks/rank_validities.qmd
+++ b/notebooks/rank_validities.qmd
@@ -16,7 +16,7 @@ import bibtexparser
sns.set_style("whitegrid")
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
PROCESSED_DATA=DATA_DIR.joinpath("processed")
diff --git a/notebooks/test-magma.qmd b/notebooks/test-magma.qmd
index 4a8d8e4..18700e8 100644
--- a/notebooks/test-magma.qmd
+++ b/notebooks/test-magma.qmd
@@ -1,5 +1,5 @@
---
-bibliography: 02-data/intermediate/zotero-library.bib
+bibliography: data/intermediate/zotero-library.bib
csl: /home/marty/documents/library/utilities/styles/APA-7.csl
papersize: A4
linestretch: 1.5
@@ -28,7 +28,7 @@ zotero:
```{python}
#| echo: false
from pathlib import Path
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
BIB_PATH = DATA_DIR.joinpath("raw/01_wos-sample_2023-11-02")
## standard imports
diff --git a/notes.qmd b/notes.qmd
index 987702a..8492eee 100644
--- a/notes.qmd
+++ b/notes.qmd
@@ -1,5 +1,5 @@
---
-bibliography: 02-data/intermediate/zotero-library.bib
+bibliography: data/intermediate/zotero-library.bib
csl: /home/marty/documents/library/utilities/styles/APA-7.csl
papersize: A4
linestretch: 1.5
@@ -22,7 +22,7 @@ subtitle: Conceptual Definitions and Key Terms
```{python}
#| echo: false
from pathlib import Path
-DATA_DIR=Path("./02-data")
+DATA_DIR=Path("./data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
PROCESSED_DATA=DATA_DIR.joinpath("processed")
@@ -396,7 +396,7 @@ Policy *areas*, identified by @ILO2022b:
#| label: tbl-inclusion-criteria
#| tbl-cap: Study inclusion and exclusion scoping criteria {#tbl-inclusion-criteria}
-inclusion_criteria = pd.read_csv("02-data/supplementary/inclusion-criteria.tsv", sep="\t")
+inclusion_criteria = pd.read_csv("data/supplementary/inclusion-criteria.tsv", sep="\t")
md(tabulate(inclusion_criteria, showindex=False, headers="keys", tablefmt="grid"))
```
diff --git a/pyproject.toml b/pyproject.toml
index 50b3648..eda0a62 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -43,19 +43,19 @@ cmd = "nvim"
[tool.poe.tasks.extract]
help = "Extract the csv data from raw yaml files"
shell = """
-python src/extract/raw_to_extracted_csv.py > 02-data/processed/extracted.csv
+python src/extract/raw_to_extracted_csv.py > data/processed/extracted.csv
"""
[tool.poe.tasks.prisma]
help = "Update PRISMA flowchart numbers"
shell = """
-python src/model/prisma.py > 02-data/processed/prisma.mmd
+python src/model/prisma.py > data/processed/prisma.mmd
"""
[tool.poe.tasks.milestone]
help = "Extract, render, commit and version a finished artifact"
shell = """
quarto render --output-dir 05-final_paper
VERSION="$(poetry version -s minor)"
-git add pyproject.toml 02-data 05-final_paper
+git add pyproject.toml data 05-final_paper
git commit -m "Publish version $VERSION" --no-gpg-sign
git tag -a -m "new bundle for $(date -Isecond)" "$VERSION"
"""
diff --git a/scoping_review.qmd b/scoping_review.qmd
index 63c206a..b26fbd6 100644
--- a/scoping_review.qmd
+++ b/scoping_review.qmd
@@ -303,7 +303,7 @@ with the search query requiring a term from the general column and one other col
```{python}
#| label: tbl-wow-terms
#| tbl-cap: World of work term cluster
-terms_wow = pd.read_csv("02-data/supplementary/terms_wow.csv")
+terms_wow = pd.read_csv("data/supplementary/terms_wow.csv")
Markdown(tabulate(terms_wow.fillna(""), showindex=False, headers="keys", tablefmt="grid"))
```
@@ -319,7 +319,7 @@ For the database query, a single term from the general category is required to b
```{python}
#| label: tbl-intervention-terms
#| tbl-cap: Policy intervention term cluster
-terms_policy = pd.read_csv("02-data/supplementary/terms_policy.csv")
+terms_policy = pd.read_csv("data/supplementary/terms_policy.csv")
# different headers to include 'social norms'
headers = ["General", "Institutional", "Structural", "Agency & social norms"]
Markdown(tabulate(terms_policy.fillna(""), showindex=False, headers=headers, tablefmt="grid"))
@@ -331,7 +331,7 @@ as seen in @tbl-inequality-terms.
```{python}
#| label: tbl-inequality-terms
#| tbl-cap: Inequality term cluster
-terms_inequality = pd.read_csv("02-data/supplementary/terms_inequality.csv")
+terms_inequality = pd.read_csv("data/supplementary/terms_inequality.csv")
Markdown(tabulate(terms_inequality.fillna(""), showindex=False, headers="keys", tablefmt="grid"))
```
@@ -355,7 +355,7 @@ with a focus on the narrowing criteria specified in @tbl-inclusion-criteria.
```{python}
#| label: inclusion-criteria
-inclusion_criteria = pd.read_csv("02-data/supplementary/inclusion-criteria.tsv", sep="\t")
+inclusion_criteria = pd.read_csv("data/supplementary/inclusion-criteria.tsv", sep="\t")
Markdown(tabulate(inclusion_criteria, showindex=False, headers="keys", tablefmt="grid"))
```
@@ -382,7 +382,7 @@ The resulting process can be seen in @fig-prisma.
```{mermaid}
%%| label: fig-prisma
%%| fig-cap: PRISMA flowchart for scoping process
-%%| file: 02-data/processed/prisma.mmd
+%%| file: data/processed/prisma.mmd
```
All relevant data concerning both their major findings and statistical significance are then extracted from the individual studies into a collective results matrix.
@@ -559,7 +559,7 @@ study_strength_bins = {
def strength_for(val):
return list(study_strength_bins.keys())[list(study_strength_bins.values()).index(val)]
-findings_institutional = pd.read_csv("02-data/supplementary/findings-institutional.csv")
+findings_institutional = pd.read_csv("data/supplementary/findings-institutional.csv")
fd_df = validity.add_to_findings(findings_institutional, by_intervention, study_strength_bins)
Markdown(tabulate(fd_df[["area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
@@ -791,7 +791,7 @@ One limitation of the study is the modelling assumption that workers will have t
#| label: tbl-findings-structural
from src.model import validity
-findings_structural = pd.read_csv("02-data/supplementary/findings-structural.csv")
+findings_structural = pd.read_csv("data/supplementary/findings-structural.csv")
fd_df = validity.add_to_findings(findings_structural, by_intervention, study_strength_bins)
Markdown(tabulate(fd_df[["area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
@@ -1028,7 +1028,7 @@ Though the intervention clearly aims at strengthening some aspect of individual
#| label: tbl-findings-agency
from src.model import validity
-findings_agency = pd.read_csv("02-data/supplementary/findings-agency.csv")
+findings_agency = pd.read_csv("data/supplementary/findings-agency.csv")
fd_df = validity.add_to_findings(findings_agency, by_intervention, study_strength_bins)
Markdown(tabulate(fd_df[["area of policy", "internal_validity", "external_validity", "findings", "channels"]].fillna(""), showindex=False, headers=["area of policy", "internal strength", "external strength", "main findings", "channels"], tablefmt="grid"))
diff --git a/src/extract/load_data.py b/src/extract/load_data.py
index fe41d36..82d791e 100644
--- a/src/extract/load_data.py
+++ b/src/extract/load_data.py
@@ -9,7 +9,7 @@ try:
except ModuleNotFoundError:
import yml as yaml # for directly running the package
-DEFAULT_YAML_PATH = Path("02-data/processed")
+DEFAULT_YAML_PATH = Path("data/processed")
def to_tsv(studies: list[dict]) -> str:
diff --git a/src/globals.py b/src/globals.py
index 76de547..9872edd 100644
--- a/src/globals.py
+++ b/src/globals.py
@@ -3,7 +3,7 @@ import os
PROJECT_DIR=Path(os.getenv("QUARTO_PROJECT_DIR", "."))
-DATA_DIR=PROJECT_DIR.joinpath("02-data")
+DATA_DIR=PROJECT_DIR.joinpath("data")
RAW_DATA=DATA_DIR.joinpath("raw")
WORKING_DATA=DATA_DIR.joinpath("intermediate")
diff --git a/src/model/prisma.py b/src/model/prisma.py
index a2e9121..56ab026 100644
--- a/src/model/prisma.py
+++ b/src/model/prisma.py
@@ -33,7 +33,7 @@ del bib_sample, bib_sample_raw_db
if __name__ == "__main__":
nr = PrismaNumbers()
- # FIXME use 02-data/supplementary undeduplciated counts to get database starting and snowballing counts
+ # FIXME use data/supplementary undeduplciated counts to get database starting and snowballing counts
outp = f"""
flowchart TD;
search_db["Records identified through database searching (n={nr.nr_database_query_raw})"] --> starting_sample;
md(tabulate(fd_df[[