Skip to content

Commit 0fe86d3

Browse files
committed
Merged origin/main into main
2 parents 6fb47bf + 8f5c519 commit 0fe86d3

File tree

5 files changed

+112
-104
lines changed

5 files changed

+112
-104
lines changed

.github/workflows/R-CMD-check.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -59,20 +59,19 @@ jobs:
5959
extra-packages: any::rcmdcheck
6060
needs: check
6161

62-
- name: Install reticulate
63-
run: pak::pkg_install('reticulate')
62+
- name: Install dev reticulate
63+
run: pak::pkg_install('rstudio/reticulate')
6464
shell: Rscript {0}
6565

66-
- name: Install Miniconda
67-
# conda can fail at downgrading python, so we specify python version in advance
68-
env:
69-
RETICULATE_MINICONDA_PYTHON_VERSION: "3.8"
70-
run: reticulate::install_miniconda() # creates r-reticulate conda env by default
71-
shell: Rscript {0}
66+
- uses: actions/setup-python@v4
67+
with:
68+
python-version: 3.11
7269

7370
- name: Install TensorFlow
7471
run: |
75-
tensorflow::install_tensorflow(version='2.13', conda_python_version = NULL)
72+
reticulate::virtualenv_create('r-reticulate', python='3.11')
73+
reticulate::use_virtualenv('r-reticulate')
74+
tensorflow::install_tensorflow(version='2.16')
7675
shell: Rscript {0}
7776

7877
- uses: r-lib/actions/check-r-package@v2

.github/workflows/pkgdown.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,14 @@ jobs:
3737
needs: website
3838

3939
- name: Install Miniconda
40-
# conda can fail at downgrading python, so we specify python version in advance
41-
env:
42-
RETICULATE_MINICONDA_PYTHON_VERSION: "3.8"
43-
run: reticulate::install_miniconda() # creates r-reticulate conda env by default
40+
run: |
41+
reticulate::install_miniconda()
4442
shell: Rscript {0}
45-
43+
4644
- name: Install TensorFlow
4745
run: |
48-
tensorflow::install_tensorflow(version='2.13', conda_python_version = NULL)
46+
reticulate::conda_create('r-reticulate', packages = c('python==3.11'))
47+
tensorflow::install_tensorflow(version='2.16')
4948
shell: Rscript {0}
5049

5150
- name: Install Torch

.github/workflows/test-coverage.yaml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,14 @@ jobs:
3232
shell: Rscript {0}
3333

3434
- name: Install Miniconda
35-
# conda can fail at downgrading python, so we specify python version in advance
36-
env:
37-
RETICULATE_MINICONDA_PYTHON_VERSION: "3.8"
38-
run: reticulate::install_miniconda() # creates r-reticulate conda env by default
35+
run: |
36+
reticulate::install_miniconda()
3937
shell: Rscript {0}
40-
38+
4139
- name: Install TensorFlow
4240
run: |
43-
tensorflow::install_tensorflow(version='2.13', conda_python_version = NULL)
41+
reticulate::conda_create('r-reticulate', packages = c('python==3.11'))
42+
tensorflow::install_tensorflow(version='2.16')
4443
shell: Rscript {0}
4544

4645
- name: Test coverage

_pkgdown.yml

Lines changed: 84 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ url: https://parsnip.tidymodels.org/
22

33
navbar:
44
components:
5-
home: ~
5+
home:
66
tutorials:
77
text: Learn more
88
menu:
@@ -20,8 +20,9 @@ template:
2020
primary: "#CA225E"
2121

2222
includes:
23-
in_header: |
24-
<script defer data-domain="parsnip.tidymodels.org,all.tidymodels.org" src="https://plausible.io/js/plausible.js"></script>
23+
in_header: |
24+
<script src="https://cdn.jsdelivr.net/gh/posit-dev/supported-by-posit/js/badge.min.js" data-max-height="43" data-hide-below="1200" data-light-bg="#666f76" data-light-fg="#f9f9f9"></script>
25+
<script defer data-domain="parsnip.tidymodels.org,all.tidymodels.org" src="https://plausible.io/js/plausible.js"></script>
2526
2627
development:
2728
mode: auto
@@ -31,84 +32,84 @@ figures:
3132
fig.height: 5.75
3233

3334
reference:
34-
- title: Models
35-
contents:
36-
- auto_ml
37-
- bag_mars
38-
- bag_mlp
39-
- bag_tree
40-
- bart
41-
- boost_tree
42-
- cubist_rules
43-
- C5_rules
44-
- decision_tree
45-
- discrim_flexible
46-
- discrim_linear
47-
- discrim_quad
48-
- discrim_regularized
49-
- gen_additive_mod
50-
- glm_grouped
51-
- linear_reg
52-
- logistic_reg
53-
- mars
54-
- mlp
55-
- multinom_reg
56-
- naive_Bayes
57-
- nearest_neighbor
58-
- null_model
59-
- pls
60-
- poisson_reg
61-
- proportional_hazards
62-
- rand_forest
63-
- rule_fit
64-
- survival_reg
65-
- svm_linear
66-
- svm_poly
67-
- svm_rbf
68-
- title: Infrastructure
69-
contents:
70-
- autoplot.model_fit
71-
- add_rowindex
72-
- augment.model_fit
73-
- case_weights
74-
- case_weights_allowed
75-
- descriptors
76-
- extract-parsnip
77-
- fit.model_spec
78-
- fit_xy
79-
- control_parsnip
80-
- glance.model_fit
81-
- matrix_to_quantile_pred
82-
- model_fit
83-
- model_formula
84-
- model_spec
85-
- multi_predict
86-
- parsnip_addin
87-
- predict.model_fit
88-
- reexports
89-
- repair_call
90-
- set_args
91-
- set_engine
92-
- set_mode
93-
- show_engines
94-
- sparse_data
95-
- tidy.model_fit
96-
- translate
97-
- starts_with("update")
98-
- matches("_train")
35+
- title: Models
36+
contents:
37+
- auto_ml
38+
- bag_mars
39+
- bag_mlp
40+
- bag_tree
41+
- bart
42+
- boost_tree
43+
- cubist_rules
44+
- C5_rules
45+
- decision_tree
46+
- discrim_flexible
47+
- discrim_linear
48+
- discrim_quad
49+
- discrim_regularized
50+
- gen_additive_mod
51+
- glm_grouped
52+
- linear_reg
53+
- logistic_reg
54+
- mars
55+
- mlp
56+
- multinom_reg
57+
- naive_Bayes
58+
- nearest_neighbor
59+
- null_model
60+
- pls
61+
- poisson_reg
62+
- proportional_hazards
63+
- rand_forest
64+
- rule_fit
65+
- survival_reg
66+
- svm_linear
67+
- svm_poly
68+
- svm_rbf
69+
- title: Infrastructure
70+
contents:
71+
- autoplot.model_fit
72+
- add_rowindex
73+
- augment.model_fit
74+
- case_weights
75+
- case_weights_allowed
76+
- descriptors
77+
- extract-parsnip
78+
- fit.model_spec
79+
- fit_xy
80+
- control_parsnip
81+
- glance.model_fit
82+
- matrix_to_quantile_pred
83+
- model_fit
84+
- model_formula
85+
- model_spec
86+
- multi_predict
87+
- parsnip_addin
88+
- predict.model_fit
89+
- reexports
90+
- repair_call
91+
- set_args
92+
- set_engine
93+
- set_mode
94+
- show_engines
95+
- sparse_data
96+
- tidy.model_fit
97+
- translate
98+
- starts_with("update")
99+
- matches("_train")
99100

100-
- title: Developer tools
101-
contents:
102-
- condense_control
103-
- contr_one_hot
104-
- set_new_model
105-
- maybe_matrix
106-
- min_cols
107-
- max_mtry_formula
108-
- required_pkgs
109-
- required_pkgs.model_spec
110-
- req_pkgs
111-
- .extract_surv_status
112-
- .extract_surv_time
113-
- .model_param_name_key
114-
- .get_prediction_column_names
101+
- title: Developer tools
102+
contents:
103+
- condense_control
104+
- contr_one_hot
105+
- set_new_model
106+
- maybe_matrix
107+
- min_cols
108+
- max_mtry_formula
109+
- required_pkgs
110+
- required_pkgs.model_spec
111+
- req_pkgs
112+
- .extract_surv_status
113+
- .extract_surv_time
114+
- .model_param_name_key
115+
- .get_prediction_column_names

vignettes/articles/Examples.Rmd

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -553,6 +553,7 @@ The following examples use consistent data sets throughout. For regression, we u
553553
Now we create the model fit object:
554554

555555
```{r}
556+
#| eval: false
556557
set.seed(1)
557558
linreg_reg_fit <- linreg_reg_spec |> fit(ridership ~ ., data = Chicago_train)
558559
linreg_reg_fit
@@ -561,6 +562,7 @@ The following examples use consistent data sets throughout. For regression, we u
561562
The holdout data can be predicted:
562563

563564
```{r}
565+
#| eval: false
564566
predict(linreg_reg_fit, Chicago_test)
565567
```
566568

@@ -791,6 +793,7 @@ The following examples use consistent data sets throughout. For regression, we u
791793
Now we create the model fit object:
792794

793795
```{r}
796+
#| eval: false
794797
set.seed(1)
795798
logreg_cls_fit <- logreg_cls_spec |> fit(Class ~ ., data = data_train)
796799
logreg_cls_fit
@@ -799,6 +802,7 @@ The following examples use consistent data sets throughout. For regression, we u
799802
The holdout data can be predicted for both hard class predictions and probabilities. We'll bind these together into one tibble:
800803

801804
```{r}
805+
#| eval: false
802806
bind_cols(
803807
predict(logreg_cls_fit, data_test),
804808
predict(logreg_cls_fit, data_test, type = "prob")
@@ -1103,6 +1107,7 @@ The following examples use consistent data sets throughout. For regression, we u
11031107
Now we create the model fit object:
11041108

11051109
```{r}
1110+
#| eval: false
11061111
set.seed(1)
11071112
mlp_reg_fit <- mlp_reg_spec |> fit(ridership ~ ., data = Chicago_train)
11081113
mlp_reg_fit
@@ -1111,6 +1116,7 @@ The following examples use consistent data sets throughout. For regression, we u
11111116
The holdout data can be predicted:
11121117

11131118
```{r}
1119+
#| eval: false
11141120
predict(mlp_reg_fit, Chicago_test)
11151121
```
11161122

@@ -1136,6 +1142,7 @@ The following examples use consistent data sets throughout. For regression, we u
11361142
Now we create the model fit object:
11371143

11381144
```{r}
1145+
#| eval: false
11391146
set.seed(1)
11401147
mlp_cls_fit <- mlp_cls_spec |> fit(Class ~ ., data = data_train)
11411148
mlp_cls_fit
@@ -1144,6 +1151,7 @@ The following examples use consistent data sets throughout. For regression, we u
11441151
The holdout data can be predicted for both hard class predictions and probabilities. We'll bind these together into one tibble:
11451152

11461153
```{r}
1154+
#| eval: false
11471155
bind_cols(
11481156
predict(mlp_cls_fit, data_test),
11491157
predict(mlp_cls_fit, data_test, type = "prob")
@@ -1365,6 +1373,7 @@ The following examples use consistent data sets throughout. For regression, we u
13651373
Now we create the model fit object:
13661374

13671375
```{r}
1376+
#| eval: false
13681377
set.seed(1)
13691378
mr_cls_fit <- mr_cls_spec |> fit(island ~ ., data = penguins_train)
13701379
mr_cls_fit
@@ -1373,6 +1382,7 @@ The following examples use consistent data sets throughout. For regression, we u
13731382
The holdout data can be predicted for both hard class predictions and probabilities. We'll bind these together into one tibble:
13741383

13751384
```{r}
1385+
#| eval: false
13761386
bind_cols(
13771387
predict(mr_cls_fit, penguins_test),
13781388
predict(mr_cls_fit, penguins_test, type = "prob")

0 commit comments

Comments
 (0)