-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefile
More file actions
44 lines (32 loc) · 1.24 KB
/
Makefile
File metadata and controls
44 lines (32 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
final_report.html: code/04_render_report.R final_project.Rmd descriptive_analysis
Rscript code/04_render_report.R
mv final_report.html final_report/
# Data cleaning
output/data_clean.rds: code/00_clean_data.R data/AirQualityUCI.csv
Rscript code/00_clean_data.R
# Table creation
output/table_stats.rds: code/01_make_table.R output/data_clean.rds
Rscript code/01_make_table.R
# Plots
output/corr_plot.png output/time_series_plot.png: code/02_make_plot.R output/data_clean.rds
Rscript code/02_make_plot.R
# Model
output/best_regression_table.rds: code/03_make_model.R output/data_clean.rds
Rscript code/03_make_model.R
.PHONY: descriptive_analysis
descriptive_analysis: output/best_regression_table.rds output/table_stats.rds output/corr_plot.png \
output/time_series_plot.png
.PHONY: clean
clean:
rm -f output/*.rds && rm -f output/*.png && rm -f final_report/*.html
.PHONY: install
install:
Rscript -e "renv::restore(prompt = FALSE)"
# Developer-only: rebuild the Docker image locally (not used for grading)
.PHONY: build_image
build_image:
docker build -t final_project_image .
.PHONY: docker_run
docker_run:
mkdir -p final_report
docker run --rm -v "$$(pwd)/final_report":/project/final_report youweihu/final_project_image bash -c "make"