Skip to content

Commit

Permalink
site deploy
Browse files Browse the repository at this point in the history
Auto-generated via `{sandpaper}`
Source  : d6986b0
Branch  : md-outputs
Author  : GitHub Actions <[email protected]>
Time    : 2024-12-24 06:14:37 +0000
Message : markdown source builds

Auto-generated via `{sandpaper}`
Source  : 4b0ed0e
Branch  : main
Author  : carpenter <[email protected]>
Time    : 2024-12-24 06:11:26 +0000
Message : Local build seems to work with mult cores
  • Loading branch information
actions-user committed Dec 24, 2024
1 parent 7efead5 commit 3c3f988
Show file tree
Hide file tree
Showing 55 changed files with 2,081 additions and 1,541 deletions.
2 changes: 1 addition & 1 deletion 404.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion CODE_OF_CONDUCT.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion LICENSE.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

771 changes: 440 additions & 331 deletions aio.html

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions basic-targets.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

514 changes: 298 additions & 216 deletions branch.html

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions cache.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions files.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 17 additions & 18 deletions files/plans/plan_10.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,27 +16,26 @@ tar_plan(
path_to_file("penguins_raw.csv"),
read_csv(!!.x, show_col_types = FALSE)
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Build models
models = list(
combined_model = lm(
bill_depth_mm ~ bill_length_mm, data = penguins_data),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species, data = penguins_data),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species, data = penguins_data)
# Clean and group data
tar_group_by(
penguins_data,
clean_penguin_data(penguins_data_raw),
species
),
# Get model summaries
# Get summary of combined model with all species together
combined_summary = model_glance_slow(penguins_data),
# Get summary of one model per species
tar_target(
model_summaries,
glance_with_mod_name_slow(models),
pattern = map(models)
species_summary,
model_glance_slow(penguins_data),
pattern = map(penguins_data)
),
# Get model predictions
# Get predictions of combined model with all species together
combined_predictions = model_augment_slow(penguins_data),
# Get predictions of one model per species
tar_target(
model_predictions,
augment_with_mod_name_slow(models),
pattern = map(models)
species_predictions,
model_augment_slow(penguins_data),
pattern = map(penguins_data)
)
)
38 changes: 18 additions & 20 deletions files/plans/plan_11.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,34 +9,32 @@ tar_plan(
path_to_file("penguins_raw.csv"),
read_csv(!!.x, show_col_types = FALSE)
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Build models
models = list(
combined_model = lm(
bill_depth_mm ~ bill_length_mm, data = penguins_data),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species, data = penguins_data),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species, data = penguins_data)
# Clean and group data
tar_group_by(
penguins_data,
clean_penguin_data(penguins_data_raw),
species
),
# Get model summaries
# Get summary of combined model with all species together
combined_summary = model_glance(penguins_data),
# Get summary of one model per species
tar_target(
model_summaries,
glance_with_mod_name(models),
pattern = map(models)
species_summary,
model_glance(penguins_data),
pattern = map(penguins_data)
),
# Get model predictions
# Get predictions of combined model with all species together
combined_predictions = model_augment(penguins_data),
# Get predictions of one model per species
tar_target(
model_predictions,
augment_with_mod_name(models),
pattern = map(models)
species_predictions,
model_augment(penguins_data),
pattern = map(penguins_data)
),
# Generate report
tar_quarto(
penguin_report,
path = "penguin_report.qmd",
quiet = FALSE,
packages = c("targets", "tidyverse")
quiet = FALSE
)
)
21 changes: 13 additions & 8 deletions files/plans/plan_5.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,21 @@ tar_plan(
bill_depth_mm ~ bill_length_mm,
data = penguins_data
),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species,
data = penguins_data
adelie_model = lm(
bill_depth_mm ~ bill_length_mm,
data = filter(penguins_data, species == "Adelie")
),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species,
data = penguins_data
chinstrap_model = lm(
bill_depth_mm ~ bill_length_mm,
data = filter(penguins_data, species == "Chinstrap")
),
gentoo_model = lm(
bill_depth_mm ~ bill_length_mm,
data = filter(penguins_data, species == "Gentoo")
),
# Get model summaries
combined_summary = glance(combined_model),
species_summary = glance(species_model),
interaction_summary = glance(interaction_model)
adelie_summary = glance(adelie_model),
chinstrap_summary = glance(chinstrap_model),
gentoo_summary = glance(gentoo_model)
)
23 changes: 11 additions & 12 deletions files/plans/plan_6.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,18 @@ tar_plan(
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Build models
models = list(
combined_model = lm(
bill_depth_mm ~ bill_length_mm, data = penguins_data),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species, data = penguins_data),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species, data = penguins_data)
# Group data
tar_group_by(
penguins_data_grouped,
penguins_data,
species
),
# Get model summaries
# Build combined model with all species together
combined_summary = model_glance(penguins_data),
# Build one model per species
tar_target(
model_summaries,
glance(models[[1]]),
pattern = map(models)
species_summary,
model_glance(penguins_data_grouped),
pattern = map(penguins_data_grouped)
)
)
28 changes: 28 additions & 0 deletions files/plans/plan_6b.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
options(tidyverse.quiet = TRUE)
source("R/packages.R")
source("R/functions.R")

tar_plan(
# Load raw data
tar_file_read(
penguins_data_raw,
path_to_file("penguins_raw.csv"),
read_csv(!!.x, show_col_types = FALSE)
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Group data
tar_group_by(
penguins_data_grouped,
penguins_data,
species
),
# Build combined model with all species together
combined_summary = model_glance_orig(penguins_data),
# Build one model per species
tar_target(
species_summary,
model_glance_orig(penguins_data_grouped),
pattern = map(penguins_data_grouped)
)
)
31 changes: 19 additions & 12 deletions files/plans/plan_7.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,26 @@ tar_plan(
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Build models
models = list(
combined_model = lm(
bill_depth_mm ~ bill_length_mm, data = penguins_data),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species, data = penguins_data),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species, data = penguins_data)
# Group data
tar_group_by(
penguins_data_grouped,
penguins_data,
species
),
# Get model summaries
# Get summary of combined model with all species together
combined_summary = model_glance(penguins_data),
# Get summary of one model per species
tar_target(
model_summaries,
glance_with_mod_name(models),
pattern = map(models)
species_summary,
model_glance(penguins_data_grouped),
pattern = map(penguins_data_grouped)
),
# Get predictions of combined model with all species together
combined_predictions = model_augment(penguins_data_grouped),
# Get predictions of one model per species
tar_target(
species_predictions,
model_augment(penguins_data_grouped),
pattern = map(penguins_data_grouped)
)
)
35 changes: 17 additions & 18 deletions files/plans/plan_8.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,27 +9,26 @@ tar_plan(
path_to_file("penguins_raw.csv"),
read_csv(!!.x, show_col_types = FALSE)
),
# Clean data
penguins_data = clean_penguin_data(penguins_data_raw),
# Build models
models = list(
combined_model = lm(
bill_depth_mm ~ bill_length_mm, data = penguins_data),
species_model = lm(
bill_depth_mm ~ bill_length_mm + species, data = penguins_data),
interaction_model = lm(
bill_depth_mm ~ bill_length_mm * species, data = penguins_data)
# Clean and group data
tar_group_by(
penguins_data,
clean_penguin_data(penguins_data_raw),
species
),
# Get model summaries
# Get summary of combined model with all species together
combined_summary = model_glance(penguins_data),
# Get summary of one model per species
tar_target(
model_summaries,
glance_with_mod_name(models),
pattern = map(models)
species_summary,
model_glance(penguins_data),
pattern = map(penguins_data)
),
# Get model predictions
# Get predictions of combined model with all species together
combined_predictions = model_augment(penguins_data),
# Get predictions of one model per species
tar_target(
model_predictions,
augment_with_mod_name(models),
pattern = map(models)
species_predictions,
model_augment(penguins_data),
pattern = map(penguins_data)
)
)
Loading

0 comments on commit 3c3f988

Please sign in to comment.