Skip to content

Commit f7fdee8

Browse files
authored
[create-pull-request] automated change
1 parent 3e6daff commit f7fdee8

File tree

12 files changed

+209
-1035
lines changed

12 files changed

+209
-1035
lines changed

tests/testthat/_snaps/deconstruct.md

Lines changed: 61 additions & 781 deletions
Large diffs are not rendered by default.

tests/testthat/_snaps/df/flatten.md

Lines changed: 54 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,18 @@
1313
Output
1414
$fact
1515
# A tibble: 10 x 7
16-
fact dim_1_key_1 dim_1_key_2 dim_2_key dim_3_key dim_4_key something~1
17-
<chr> <int> <chr> <chr> <chr> <int> <int>
18-
1 acorn 14 N c X 7 1
19-
2 blubber 13 M d W 8 2
20-
3 cinderella 12 L e V 9 3
21-
4 depth 11 K f U 10 4
22-
5 elysium 10 J g T 11 5
23-
6 fantasy 9 I h S 12 6
24-
7 gorgeous 8 H i R 13 7
25-
8 halo 7 G j Q 14 8
26-
9 ill-advised 6 F k P 15 9
27-
10 jitter 5 E l O 16 10
28-
# ... with abbreviated variable name 1: something.fact
16+
fact dim_1_key_1 dim_1_key_2 dim_2_key dim_3_key dim_4_key something.fact
17+
<chr> <int> <chr> <chr> <chr> <int> <int>
18+
1 acorn 14 N c X 7 1
19+
2 blubber 13 M d W 8 2
20+
3 cindere~ 12 L e V 9 3
21+
4 depth 11 K f U 10 4
22+
5 elysium 10 J g T 11 5
23+
6 fantasy 9 I h S 12 6
24+
7 gorgeous 8 H i R 13 7
25+
8 halo 7 G j Q 14 8
26+
9 ill-adv~ 6 F k P 15 9
27+
10 jitter 5 E l O 16 10
2928
3029
$dim_1
3130
# A tibble: 20 x 3
@@ -131,63 +130,57 @@
131130
dm_rename(dim_4, something.dim_4 = something)
132131
Output
133132
# A tibble: 10 x 11
134-
fact dim_1~1 dim_1~2 dim_2~3 dim_3~4 dim_4~5 somet~6 somet~7 somet~8 somet~9
135-
<chr> <int> <chr> <chr> <chr> <int> <int> <chr> <chr> <int>
136-
1 acorn 14 N c X 7 1 p G 22
137-
2 blub~ 13 M d W 8 2 o H 21
138-
3 cind~ 12 L e V 9 3 n I 20
139-
4 depth 11 K f U 10 4 m J 19
140-
5 elys~ 10 J g T 11 5 l K 18
141-
6 fant~ 9 I h S 12 6 k L 17
142-
7 gorg~ 8 H i R 13 7 j M 16
143-
8 halo 7 G j Q 14 8 i N 15
144-
9 ill-~ 6 F k P 15 9 h O 14
145-
10 jitt~ 5 E l O 16 10 g P 13
146-
# ... with 1 more variable: something.dim_4 <int>, and abbreviated variable
147-
# names 1: dim_1_key_1, 2: dim_1_key_2, 3: dim_2_key, 4: dim_3_key,
148-
# 5: dim_4_key, 6: something.fact, 7: something.dim_1, 8: something.dim_2,
149-
# 9: something.dim_3
133+
fact dim_1_key_1 dim_1_key_2 dim_2_key dim_3_key dim_4_key something.fact
134+
<chr> <int> <chr> <chr> <chr> <int> <int>
135+
1 acorn 14 N c X 7 1
136+
2 blubber 13 M d W 8 2
137+
3 cindere~ 12 L e V 9 3
138+
4 depth 11 K f U 10 4
139+
5 elysium 10 J g T 11 5
140+
6 fantasy 9 I h S 12 6
141+
7 gorgeous 8 H i R 13 7
142+
8 halo 7 G j Q 14 8
143+
9 ill-adv~ 6 F k P 15 9
144+
10 jitter 5 E l O 16 10
145+
# i 4 more variables: something.dim_1 <chr>, something.dim_2 <chr>,
146+
# something.dim_3 <int>, something.dim_4 <int>
150147
Code
151148
result_from_flatten_new()
152149
Output
153150
# A tibble: 10 x 11
154-
fact dim_1~1 dim_1~2 dim_2~3 dim_3~4 dim_4~5 somet~6 somet~7 somet~8 somet~9
155-
<chr> <int> <chr> <chr> <chr> <int> <int> <chr> <chr> <int>
156-
1 acorn 14 N c X 7 1 p G 22
157-
2 blub~ 13 M d W 8 2 o H 21
158-
3 cind~ 12 L e V 9 3 n I 20
159-
4 depth 11 K f U 10 4 m J 19
160-
5 elys~ 10 J g T 11 5 l K 18
161-
6 fant~ 9 I h S 12 6 k L 17
162-
7 gorg~ 8 H i R 13 7 j M 16
163-
8 halo 7 G j Q 14 8 i N 15
164-
9 ill-~ 6 F k P 15 9 h O 14
165-
10 jitt~ 5 E l O 16 10 g P 13
166-
# ... with 1 more variable: something.dim_4 <int>, and abbreviated variable
167-
# names 1: dim_1_key_1, 2: dim_1_key_2, 3: dim_2_key, 4: dim_3_key,
168-
# 5: dim_4_key, 6: something.fact, 7: something.dim_1, 8: something.dim_2,
169-
# 9: something.dim_3
151+
fact dim_1_key_1 dim_1_key_2 dim_2_key dim_3_key dim_4_key something.fact
152+
<chr> <int> <chr> <chr> <chr> <int> <int>
153+
1 acorn 14 N c X 7 1
154+
2 blubber 13 M d W 8 2
155+
3 cindere~ 12 L e V 9 3
156+
4 depth 11 K f U 10 4
157+
5 elysium 10 J g T 11 5
158+
6 fantasy 9 I h S 12 6
159+
7 gorgeous 8 H i R 13 7
160+
8 halo 7 G j Q 14 8
161+
9 ill-adv~ 6 F k P 15 9
162+
10 jitter 5 E l O 16 10
163+
# i 4 more variables: something.dim_1 <chr>, something.dim_2 <chr>,
164+
# something.dim_3 <int>, something.dim_4 <int>
170165

171166
# `dm_flatten_to_tbl()` does the right things for 'inner_join()'
172167

173168
Code
174169
out
175170
Output
176171
# A tibble: 10 x 11
177-
fact dim_1~1 dim_1~2 dim_2~3 dim_3~4 dim_4~5 somet~6 somet~7 somet~8 somet~9
178-
<chr> <int> <chr> <chr> <chr> <int> <int> <chr> <chr> <int>
179-
1 acorn 14 N c X 7 1 p G 22
180-
2 blub~ 13 M d W 8 2 o H 21
181-
3 cind~ 12 L e V 9 3 n I 20
182-
4 depth 11 K f U 10 4 m J 19
183-
5 elys~ 10 J g T 11 5 l K 18
184-
6 fant~ 9 I h S 12 6 k L 17
185-
7 gorg~ 8 H i R 13 7 j M 16
186-
8 halo 7 G j Q 14 8 i N 15
187-
9 ill-~ 6 F k P 15 9 h O 14
188-
10 jitt~ 5 E l O 16 10 g P 13
189-
# ... with 1 more variable: something.dim_4 <int>, and abbreviated variable
190-
# names 1: dim_1_key_1, 2: dim_1_key_2, 3: dim_2_key, 4: dim_3_key,
191-
# 5: dim_4_key, 6: something.fact, 7: something.dim_1, 8: something.dim_2,
192-
# 9: something.dim_3
172+
fact dim_1_key_1 dim_1_key_2 dim_2_key dim_3_key dim_4_key something.fact
173+
<chr> <int> <chr> <chr> <chr> <int> <int>
174+
1 acorn 14 N c X 7 1
175+
2 blubber 13 M d W 8 2
176+
3 cindere~ 12 L e V 9 3
177+
4 depth 11 K f U 10 4
178+
5 elysium 10 J g T 11 5
179+
6 fantasy 9 I h S 12 6
180+
7 gorgeous 8 H i R 13 7
181+
8 halo 7 G j Q 14 8
182+
9 ill-adv~ 6 F k P 15 9
183+
10 jitter 5 E l O 16 10
184+
# i 4 more variables: something.dim_1 <chr>, something.dim_2 <chr>,
185+
# something.dim_3 <int>, something.dim_4 <int>
193186

tests/testthat/_snaps/disentangle.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
8 d-2 d e-3 e no_action
6565
9 d-1 d f-2 f no_action
6666
10 d-2 d f-4 f no_action
67-
# ... with 12 more rows
67+
# i 12 more rows
6868
Code
6969
dm_disentangle(entangled_dm(), c) %>% dm_get_all_fks()
7070
Message
@@ -89,7 +89,7 @@
8989
8 d-2 d e-3 e no_action
9090
9 d-1 d f-2 f no_action
9191
10 d-2 d f-4 f no_action
92-
# ... with 12 more rows
92+
# i 12 more rows
9393
Code
9494
dm_disentangle(entangled_dm_2(), a) %>% dm_get_all_fks()
9595
Message

0 commit comments

Comments
 (0)