-
Notifications
You must be signed in to change notification settings - Fork 2
/
.Rhistory
512 lines (512 loc) · 32.3 KB
/
.Rhistory
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
names(牍) <- gsub('\\(百万吨油当量|\\(百万吨', '(百万吨)', names(牍))
names(牍) <- gsub('\\(\\%|\\(\\‰', '(百分比)', names(牍))
names(牍) <- gsub('\\(十亿桶', '(十亿桶)', names(牍))
names(牍) <- gsub('\\(吨', '(吨)', names(牍))
names(牍) <- gsub('\\(元', '(元)', names(牍))
names(牍) <- gsub('\\(吨', '(吨)', names(牍))
names(牍) <- gsub('\\(亿美元', '(亿美元)', names(牍))
牍[grep('(亿美元)', names(牍))] <- round(牍[grep('(亿美元)', names(牍))] * 100000000)
names(牍) <- gsub('(美元)亿美元|(亿美元)', '(美元)', names(牍))
names(牍) <- gsub('\\/人|\\(辆|\\(张| 55056', '', names(牍))
names(牍) <- gsub(':', ':', names(牍))
names(牍) <- gsub('::', ':', names(牍))
names(牍) <- gsub('^人民币', '', names(牍))
names(牍) <- gsub('中国实际使用外资金额', '外资实货量', names(牍))
names(牍) <- gsub('GDP|GDP:', '钱谷', names(牍))
names(牍) <- gsub('^人均钱谷(美元)美元$', '人均钱谷(美元)', names(牍))
names(牍) <- gsub('^钱谷*.+百万美元$', '钱谷(百万美元)', names(牍))
names(牍) <- gsub('\\(个|\\(所:|登记', '', names(牍))
names(牍) <- gsub('\\(亿\\)', '(亿)', names(牍))
牍[grep('(亿)', names(牍))] <- round(牍[grep('(亿)', names(牍))] * 100000000)
names(牍) <- gsub('(亿)', '', names(牍))
names(牍) <- gsub('\\(个:', '', names(牍))
names(牍) <- gsub('\\(所:|\\(所', '', names(牍))
names(牍) <- gsub('\\(港元', '(港元)', names(牍))
牍[grep('(百万港元)', names(牍))] <- round(牍[grep('(百万港元)', names(牍))] * 1000000)
names(牍) <- gsub('\\(百万港元', '(港元)', names(牍))
names(牍) <- gsub(':全球占比|占世界比重|:占全球比例|比重', '占全球', names(牍))
names(牍) <- gsub('占比', '', names(牍))
names(牍) <- gsub('高职\\(专科\\)', '专科', names(牍))
names(牍) <- gsub('\\(购买力平价\\)\\(国际元', '', names(牍))
names(牍) <- gsub('\\(亿千瓦时', '(亿千瓦时)', names(牍))
names(牍) <- gsub('(亿千瓦时)', '(亿千瓦时)', names(牍))
names(牍) <- gsub('老年人占总人口占全球', '老年人口占全球', names(牍))
names(牍) <- gsub('占钱谷占全球', '占全球钱谷', names(牍))
names(牍) <- gsub('\\(10亿立方米', '(十亿立方米)', names(牍))
names(牍) <- gsub('老年人人口总数', '老年人口总数', names(牍))
names(牍) <- gsub('高等学校在校学生数|高等学校本专科在校学生数', '高校在校学生数', names(牍))
names(牍) <- gsub('\\(平方公里', '(平方公里)', names(牍))
names(牍) <- gsub('\\(床', '', names(牍))
names(牍) <- gsub('\\(活产男婴/活产女婴', '(男/女)', names(牍))
names(牍) <- gsub('(元)/平方米', '(元/平方米)', names(牍))
names(牍) <- gsub(':|::', '', names(牍))
names(牍) <- gsub('\\(本国货币单位', '(本国货币单位)', names(牍))
names(牍) <- gsub('\\(本币\\)\\(欧元', '(欧元)', names(牍))
names(牍) <- gsub('\\(医院和卫生院床位数\\(家|医院和卫生院床位数\\(家|^医院床位数和卫生院|^医院和卫生院床位数$|^医院床位数$|^医疗卫生机构床位数$|^病床数$|^医院、卫生院床位数$', '医院和诊疗所床数', names(牍))
names(牍) <- gsub('\\(含劳务派遣\\)', '(含劳务派遣)', names(牍))
names(牍) <- gsub('\\(本国货币单位', '(本国货币单位)', names(牍))
names(牍) <- gsub('男性占总人口占全球(百分比)', '男性占全球人口(百分比)', names(牍))
names(牍) <- gsub('女性占总人口占全球(百分比)', '女性占全球人口(百分比)', names(牍))
names(牍) <- gsub('总人口数|^总人口$|^户籍总人口$', '户籍人口', names(牍))
names(牍) <- gsub('人口总数|人数|人口总数|人口数量', '人口', names(牍))
names(牍) <- gsub('常住人口', '人口', names(牍))
names(牍) <- gsub(' $', '', names(牍))
names(牍) <- gsub('年平均', '平均', names(牍))
names(牍) <- gsub('职工(含劳务派遣)平均工资(元)|全部单位职工平均工资(元)|城镇单位职工平均工资(元)', '职工平均工资(元)', names(牍))
# lapply(牍, class)
names(牍) <- gsub('^钱谷增长率*.+$', '钱谷增长率(百分比)', names(牍))
names(牍) <- gsub('^在校小*.+$|小学*.+$', '在校小学生', names(牍))
names(牍) <- gsub('^高等*.+$|^高校*.+$', '在校高学生', names(牍))
names(牍) <- gsub('^专科*.+$|^本专科*.+$', '在校高专生', names(牍))
# 版[grep('.id|时间|农村|农牧|农民|城镇', names(版), value = TRUE)] %>%
# .[rowSums(!is.na(版[grep('城镇化率', names(版), value = TRUE)])) > 0, ] # %>% names
# .[1001:1l500,] %>% data.frame
names(牍) <- gsub('农村居民|农牧民|农牧居民|渔农村居民', '农林牧渔民', names(牍))
names(牍) <- gsub('城镇居民', '邑民', names(牍)) #攻城堕邑,城镇故称「邑」
牍$`农林牧渔民可支配收入(人民币)` <- rowSums(牍[grep('农林牧渔民可支配收入', names(牍))], na.rm = TRUE) %>% na_if(0)
牍[grep('农林牧渔民可支配收入', names(牍))] <- NULL
牍$`邑民人均可支配收入(人民币)` <- rowSums(牍[grep('居民人均可支配收入', names(牍))], na.rm = TRUE) %>% na_if(0)
牍[grep('居民人均可支配收入', names(牍))] <- NULL
牍$地方财税 <- rowSums(牍[grep('地方|财政|税收收入', names(牍))], na.rm = TRUE) %>% na_if(0)
牍[grep('财政|税收收入', names(牍))] <- NULL
names(牍) <- gsub('存款余额个人储蓄存款|居民储蓄存款余额', '居民储蓄', names(牍))
names(牍) <- gsub('^居民储蓄存款余额(亿人民币)$|^存款余额个人储蓄存款(亿人民币)$|^城乡居民储蓄余额(亿人民币)$|^本外币居民储蓄(亿人民币)$|^城乡居民储蓄(亿人民币)$|^储蓄存款余额(亿人民币)$|^居民储蓄余额(亿人民币)$|^城乡居民储蓄(亿人民币)$|^本外币居民储蓄(亿人民币)$', '居民储蓄(亿人民币)', names(牍))
牍$`居民储蓄(亿人民币)` <- NULL
names(牍) <- gsub('^城乡居民储蓄余额$|居民储蓄存款余额|^城乡居民储蓄$|^居民储蓄余额$', '居民储蓄', names(牍))
names(牍) <- gsub('(元)', '(人民币)', names(牍))
names(牍) <- gsub('^存款余额住户存款$|^本外币存款余额境内住户存款$|^存款余额境内住户存款$|^本外币住户存款余额$|^本外币存款余额住户存款$|^住户存款余额$|^存款余额境内存款-个人存款$', '本外币余额(人民币)', names(牍))
names(牍) <- gsub('^住户存款余额(亿人民币)$|^存款余额境内住户存款(亿人民币)$|^本外币存款余额住户存款(亿人民币)$|^本外币住户存款余额(亿人民币)$|^存款余额住户存款(亿人民币)$|^本外币存款余额境内住户存款(亿人民币)$|^住户本外币存款余额(亿人民币)$|^存款余额境内存款住户存款(亿人民币)$|^个人存款余额(亿人民币)$|^本外币境内住户贷款余额(亿人民币)$', '本外币余额(亿人民币)', names(牍))
牍$`本外币余额(亿人民币)` <- NULL
牍[grep('(亿人民币)', names(牍))] <- round(牍[grep('(亿人民币)', names(牍))] * 100000000)
names(牍) <- gsub('^本外币居民储蓄$|^住户本外币存款余额$|^本外币境内住户贷款余额$|^储蓄存款余额$|^存款余额境内存款住户存款$|^个人存款余额$', '本外币余额(人民币)', names(牍))
names(牍) <- gsub('\\(本国货币|(本国货币单位)', '(本国币种)', names(牍))
names(牍) <- gsub('通货膨涨率\\(CPI\\)', '消费指数通胀率', names(牍))
names(牍) <- gsub('城镇', '城邑', names(牍))
names(牍) <- gsub('港货物吞吐量', '港口吞吐量', names(牍))
# 制造业和工业的区别和联系:https://worktile.com/kb/ask/11799.html
names(牍) <- gsub('制造业', '工业', names(牍))
names(牍) <- gsub('^全球', '', names(牍))
names(牍) <- gsub('时间', '年份', names(牍))
# names(牍) <- gsub('^城乡居民储蓄余额$|^住户本外币存款余额$|^本外币境内住户贷款余额$', '本外币余额(人民币)', names(牍))
# 牍$`存款余额住户存款(亿人民币)` %<>% replace(is.na(.), 'NA')
#牍乙 = 牍[-1][rowSums(!is.na(牍[-1])) > 0,]
#牍丙 = dplyr::inner_join(牍[c('时间', '人口')], 牍乙)
#牍 %<>% replace_na_dt(to = 'NA')
牍
}) %>%
plyr::ldply(.id = '天下') %>%
as.data.table() # as_tibble()
聚汇数据 <- 版
# 聚汇数据[, 年份 := data.table::year(年份)]
## ??data.table::year 中的year()函数数据矢量属于int数据类型
## ??integer
## ??round
# data.table::year(round(聚汇数据$年份))
# round(聚汇数据$年份)
聚汇数据 <- 聚汇数据[rowSums(!is.na(聚汇数据[,-c(1:2)])) > 0, ]
聚汇数据
聚汇数据 <- 聚汇数据[年份 != 199]
聚汇数据
saveRDS(聚汇数据, paste0(.蜀道, '诸子百家学府/聚汇数据.rds'))
if (!is.data.table(聚汇数据)) 聚汇数据 %<>% as.data.table
## 天下各别数据
天下数据 <- 聚汇数据[!grep('全世界', 天下)]
## 天下总和数据
总汇数据 <- 聚汇数据[grep('全世界', 天下)]
## 检验是否已设置途径。
# source('函数/...R')
# source('函数/....R')
## 秦国 China,秦人 Chinese
## 司马错得蜀既得楚
if (!exists('.蜀道')) {
.蜀道 <- getwd() |>
{\(.) str_split(., '/')}() |>
{\(.) c('/', .[[1]][2:5])}() |>
{\(.) c(., 'zhongkehongqi-cangku/')}() |>
{\(.) paste(., collapse = '/')}() |>
{\(.) substring(., 2)}()
}
if (!exists('聚汇数据')) {
聚汇数据 <- readRDS(paste0(.蜀道, '诸子百家学府/聚汇数据.rds'))
}
# conflicted::conflicts_prefer(data.table::`:=`)
if (!is.data.table(聚汇数据)) 聚汇数据 %<>% as.data.table
## 天下各别数据
天下数据 <- 聚汇数据[!grep('全世界', 天下)]
## 天下总和数据
总汇数据 <- 聚汇数据[grep('全世界', 天下)]
## 绘制聚汇数据图表
聚汇数据[c(1:3, (nrow(聚汇数据) - 3):nrow(聚汇数据)),] |>
{\(.) kbl(., caption = '聚汇数据:左氏春秋,鸟瞰天下', escape = FALSE)}() |>
## https://www.w3schools.com/cssref/css_colors.asp
## https://public.tableau.com/en-us/gallery/100-color-palettes?gallery=votd
{\(.) row_spec(., 0, background = 'DimGrey',
color = 'gold', bold = TRUE)}() |>
{\(.) column_spec(., 1, background = '#991B00')}() |>
{\(.) column_spec(., 2, background = '#D52600')}() |>
{\(.) column_spec(., 3, background = 'DarkGrey')}() |>
{\(.) column_spec(., 4, background = 'Gray')}() |>
{\(.) column_spec(., 5, background = 'DarkGrey')}() |>
{\(.) column_spec(., 6, background = 'Gray')}() |>
{\(.) column_spec(., 7, background = 'DarkGrey')}() |>
{\(.) column_spec(., 8, background = 'Gray')}() |>
{\(.) column_spec(., 9, background = 'DarkGrey')}() |>
{\(.) column_spec(., 10, background = 'Gray')}() |>
{\(.) column_spec(., 11, background = 'DarkGrey')}() |>
{\(.) column_spec(., 12, background = 'Gray')}() |>
{\(.) column_spec(., 13, background = 'DarkGrey')}() |>
{\(.) column_spec(., 14, background = 'Gray')}() |>
{\(.) column_spec(., 15, background = 'DarkGrey')}() |>
{\(.) column_spec(., 16, background = 'Gray')}() |>
{\(.) column_spec(., 17, background = 'DarkGrey')}() |>
{\(.) column_spec(., 18, background = 'Gray')}() |>
{\(.) column_spec(., 19, background = 'DarkGrey')}() |>
{\(.) column_spec(., 20, background = 'Gray')}() |>
{\(.) column_spec(., 21, background = 'DarkGrey')}() |>
{\(.) column_spec(., 22, background = 'Gray')}() |>
{\(.) column_spec(., 23, background = 'DarkGrey')}() |>
{\(.) column_spec(., 24, background = 'Gray')}() |>
{\(.) column_spec(., 25, background = 'DarkGrey')}() |>
{\(.) column_spec(., 26, background = 'Gray')}() |>
{\(.) column_spec(., 27, background = 'DarkGrey')}() |>
{\(.) column_spec(., 28, background = 'Gray')}() |>
{\(.) column_spec(., 29, background = 'DarkGrey')}() |>
{\(.) column_spec(., 30, background = 'Gray')}() |>
{\(.) column_spec(., 31, background = 'DarkGrey')}() |>
{\(.) column_spec(., 32, background = 'Gray')}() |>
{\(.) column_spec(., 33, background = 'DarkGrey')}() |>
{\(.) column_spec(., 34, background = 'Gray')}() |>
{\(.) column_spec(., 35, background = 'DarkGrey')}() |>
{\(.) column_spec(., 36, background = 'Gray')}() |>
{\(.) column_spec(., 37, background = 'DarkGrey')}() |>
{\(.) column_spec(., 38, background = 'Gray')}() |>
{\(.) column_spec(., 39, background = 'DarkGrey')}() |>
{\(.) column_spec(., 40, background = 'Gray')}() |>
{\(.) column_spec(., 41, background = 'DarkGrey')}() |>
{\(.) column_spec(., 42, background = 'Gray')}() |>
{\(.) column_spec(., 43, background = 'DarkGrey')}() |>
{\(.) column_spec(., 44, background = 'Gray')}() |>
{\(.) column_spec(., 45, background = 'DarkGrey')}() |>
{\(.) column_spec(., 46, background = 'Gray')}() |>
{\(.) column_spec(., 47, background = 'DarkGrey')}() |>
{\(.) column_spec(., 48, background = 'Gray')}() |>
{\(.) column_spec(., 49, background = 'DarkGrey')}() |>
{\(.) column_spec(., 50, background = 'Gray')}() |>
{\(.) column_spec(., 51, background = 'DarkGrey')}() |>
{\(.) column_spec(., 52, background = 'Gray')}() |>
{\(.) column_spec(., 53, background = 'DarkGrey')}() |>
{\(.) column_spec(., 54, background = 'Gray')}() |>
{\(.) column_spec(., 55, background = 'DarkGrey')}() |>
{\(.) column_spec(., 56, background = 'Gray')}() |>
{\(.) column_spec(., 57, background = 'DarkGrey')}() |>
{\(.) column_spec(., 58, background = 'Gray')}() |>
{\(.) column_spec(., 59, background = 'DarkGrey')}() |>
{\(.) column_spec(., 60, background = 'Gray')}() |>
{\(.) column_spec(., 61, background = 'DarkGrey')}() |>
{\(.) column_spec(., 62, background = 'Gray')}() |>
{\(.) column_spec(., 63, background = 'DarkGrey')}() |>
{\(.) column_spec(., 64, background = 'Gray')}() |>
{\(.) column_spec(., 65, background = 'DarkGrey')}() |>
{\(.) column_spec(., 66, background = 'Gray')}() |>
{\(.) column_spec(., 67, background = 'DarkGrey')}() |>
{\(.) column_spec(., 68, background = 'Gray')}() |>
{\(.) column_spec(., 69, background = 'DarkGrey')}() |>
{\(.) column_spec(., 70, background = 'Gray')}() |>
{\(.) column_spec(., 71, background = 'DarkGrey')}() |>
{\(.) column_spec(., 72, background = 'Gray')}() |>
{\(.) column_spec(., 73, background = 'DarkGrey')}() |>
{\(.) column_spec(., 74, background = 'Gray')}() |>
{\(.) column_spec(., 75, background = 'DarkGrey')}() |>
{\(.) column_spec(., 76, background = 'Gray')}() |>
{\(.) column_spec(., 77, background = 'DarkGrey')}() |>
{\(.) column_spec(., 78, background = 'Gray')}() |>
{\(.) column_spec(., 79, background = 'DarkGrey')}() |>
{\(.) column_spec(., 80, background = 'Gray')}() |>
{\(.) column_spec(., 81, background = 'DarkGrey')}() |>
{\(.) column_spec(., 82, background = 'Gray')}() |>
{\(.) column_spec(., 83, background = 'DarkGrey')}() |>
{\(.) column_spec(., 84, background = 'Gray')}() |>
{\(.) column_spec(., 85, background = 'DarkGrey')}() |>
{\(.) column_spec(., 86, background = 'Gray')}() |>
{\(.) column_spec(., 87, background = 'DarkGrey')}() |>
{\(.) column_spec(., 88, background = 'Gray')}() |>
{\(.) column_spec(., 89, background = 'DarkGrey')}() |>
{\(.) column_spec(., 90, background = 'Gray')}() |>
{\(.) column_spec(., 91, background = 'DarkGrey')}() |>
{\(.) column_spec(., 92, background = 'Gray')}() |>
{\(.) column_spec(., 93, background = 'DarkGrey')}() |>
{\(.) column_spec(., 94, background = 'Gray')}() |>
{\(.) column_spec(., 95, background = 'DarkGrey')}() |>
{\(.) column_spec(., 96, background = 'Gray')}() |>
{\(.) column_spec(., 97, background = 'DarkGrey')}() |>
{\(.) column_spec(., 98, background = 'Gray')}() |>
{\(.) column_spec(., 99, background = 'DarkGrey')}() |>
{\(.) column_spec(., 100, background = 'Gray')}() |>
{\(.) column_spec(., 101, background = 'DarkGrey')}() |>
{\(.) column_spec(., 102, background = 'Gray')}() |>
{\(.) column_spec(., 103, background = 'DarkGrey')}() |>
{\(.) column_spec(., 104, background = 'Gray')}() |>
{\(.) column_spec(., 105, background = 'DarkGrey')}() |>
{\(.) column_spec(., 106, background = 'Gray')}() |>
{\(.) column_spec(., 107, background = 'DarkGrey')}() |>
{\(.) column_spec(., 108, background = 'Gray')}() |>
{\(.) column_spec(., 109, background = 'DarkGrey')}() |>
{\(.) column_spec(., 110, background = 'Gray')}() |>
{\(.) column_spec(., 111, background = 'DarkGrey')}() |>
{\(.) column_spec(., 112, background = 'Gray')}() |>
{\(.) column_spec(., 113, background = 'DarkGrey')}() |>
{\(.) column_spec(., 114, background = 'Gray')}() |>
# {\(.) column_spec(., 12, background = 'LightGray',
# color = 'goldenrod')}() |>
{\(.) kable_styling(., bootstrap_options =
c('striped', 'hover', 'condensed', 'responsive'))}() |>
##`full_width = FALSE`是将每列设置为伸缩性自动调整宽度。
{\(.) kable_material(., full_width = FALSE)}() |>
{\(.) scroll_box(., width = '100%', fixed_thead = TRUE,
height = '490px')}()
## 绘制天下数据图表
总汇数据 |>
{\(.) kbl(., caption = '聚汇数据:左氏春秋,鸟瞰天下', escape = FALSE)}() |>
## https://www.w3schools.com/cssref/css_colors.asp
## https://public.tableau.com/en-us/gallery/100-color-palettes?gallery=votd
{\(.) row_spec(., 0, background = 'DimGrey',
color = 'gold', bold = TRUE)}() |>
{\(.) column_spec(., 1, background = '#991B00')}() |>
{\(.) column_spec(., 2, background = '#D52600')}() |>
{\(.) column_spec(., 3, background = 'DarkGrey')}() |>
{\(.) column_spec(., 4, background = 'Gray')}() |>
{\(.) column_spec(., 5, background = 'DarkGrey')}() |>
{\(.) column_spec(., 6, background = 'Gray')}() |>
{\(.) column_spec(., 7, background = 'DarkGrey')}() |>
{\(.) column_spec(., 8, background = 'Gray')}() |>
{\(.) column_spec(., 9, background = 'DarkGrey')}() |>
{\(.) column_spec(., 10, background = 'Gray')}() |>
{\(.) column_spec(., 11, background = 'DarkGrey')}() |>
{\(.) column_spec(., 12, background = 'Gray')}() |>
{\(.) column_spec(., 13, background = 'DarkGrey')}() |>
{\(.) column_spec(., 14, background = 'Gray')}() |>
{\(.) column_spec(., 15, background = 'DarkGrey')}() |>
{\(.) column_spec(., 16, background = 'Gray')}() |>
{\(.) column_spec(., 17, background = 'DarkGrey')}() |>
{\(.) column_spec(., 18, background = 'Gray')}() |>
{\(.) column_spec(., 19, background = 'DarkGrey')}() |>
{\(.) column_spec(., 20, background = 'Gray')}() |>
{\(.) column_spec(., 21, background = 'DarkGrey')}() |>
{\(.) column_spec(., 22, background = 'Gray')}() |>
{\(.) column_spec(., 23, background = 'DarkGrey')}() |>
{\(.) column_spec(., 24, background = 'Gray')}() |>
{\(.) column_spec(., 25, background = 'DarkGrey')}() |>
{\(.) column_spec(., 26, background = 'Gray')}() |>
{\(.) column_spec(., 27, background = 'DarkGrey')}() |>
{\(.) column_spec(., 28, background = 'Gray')}() |>
{\(.) column_spec(., 29, background = 'DarkGrey')}() |>
{\(.) column_spec(., 30, background = 'Gray')}() |>
{\(.) column_spec(., 31, background = 'DarkGrey')}() |>
{\(.) column_spec(., 32, background = 'Gray')}() |>
{\(.) column_spec(., 33, background = 'DarkGrey')}() |>
{\(.) column_spec(., 34, background = 'Gray')}() |>
{\(.) column_spec(., 35, background = 'DarkGrey')}() |>
{\(.) column_spec(., 36, background = 'Gray')}() |>
{\(.) column_spec(., 37, background = 'DarkGrey')}() |>
{\(.) column_spec(., 38, background = 'Gray')}() |>
{\(.) column_spec(., 39, background = 'DarkGrey')}() |>
{\(.) column_spec(., 40, background = 'Gray')}() |>
{\(.) column_spec(., 41, background = 'DarkGrey')}() |>
{\(.) column_spec(., 42, background = 'Gray')}() |>
{\(.) column_spec(., 43, background = 'DarkGrey')}() |>
{\(.) column_spec(., 44, background = 'Gray')}() |>
{\(.) column_spec(., 45, background = 'DarkGrey')}() |>
{\(.) column_spec(., 46, background = 'Gray')}() |>
{\(.) column_spec(., 47, background = 'DarkGrey')}() |>
{\(.) column_spec(., 48, background = 'Gray')}() |>
{\(.) column_spec(., 49, background = 'DarkGrey')}() |>
{\(.) column_spec(., 50, background = 'Gray')}() |>
{\(.) column_spec(., 51, background = 'DarkGrey')}() |>
{\(.) column_spec(., 52, background = 'Gray')}() |>
{\(.) column_spec(., 53, background = 'DarkGrey')}() |>
{\(.) column_spec(., 54, background = 'Gray')}() |>
{\(.) column_spec(., 55, background = 'DarkGrey')}() |>
{\(.) column_spec(., 56, background = 'Gray')}() |>
{\(.) column_spec(., 57, background = 'DarkGrey')}() |>
{\(.) column_spec(., 58, background = 'Gray')}() |>
{\(.) column_spec(., 59, background = 'DarkGrey')}() |>
{\(.) column_spec(., 60, background = 'Gray')}() |>
{\(.) column_spec(., 61, background = 'DarkGrey')}() |>
{\(.) column_spec(., 62, background = 'Gray')}() |>
{\(.) column_spec(., 63, background = 'DarkGrey')}() |>
{\(.) column_spec(., 64, background = 'Gray')}() |>
{\(.) column_spec(., 65, background = 'DarkGrey')}() |>
{\(.) column_spec(., 66, background = 'Gray')}() |>
{\(.) column_spec(., 67, background = 'DarkGrey')}() |>
{\(.) column_spec(., 68, background = 'Gray')}() |>
{\(.) column_spec(., 69, background = 'DarkGrey')}() |>
{\(.) column_spec(., 70, background = 'Gray')}() |>
{\(.) column_spec(., 71, background = 'DarkGrey')}() |>
{\(.) column_spec(., 72, background = 'Gray')}() |>
{\(.) column_spec(., 73, background = 'DarkGrey')}() |>
{\(.) column_spec(., 74, background = 'Gray')}() |>
{\(.) column_spec(., 75, background = 'DarkGrey')}() |>
{\(.) column_spec(., 76, background = 'Gray')}() |>
{\(.) column_spec(., 77, background = 'DarkGrey')}() |>
{\(.) column_spec(., 78, background = 'Gray')}() |>
{\(.) column_spec(., 79, background = 'DarkGrey')}() |>
{\(.) column_spec(., 80, background = 'Gray')}() |>
{\(.) column_spec(., 81, background = 'DarkGrey')}() |>
{\(.) column_spec(., 82, background = 'Gray')}() |>
{\(.) column_spec(., 83, background = 'DarkGrey')}() |>
{\(.) column_spec(., 84, background = 'Gray')}() |>
{\(.) column_spec(., 85, background = 'DarkGrey')}() |>
{\(.) column_spec(., 86, background = 'Gray')}() |>
{\(.) column_spec(., 87, background = 'DarkGrey')}() |>
{\(.) column_spec(., 88, background = 'Gray')}() |>
{\(.) column_spec(., 89, background = 'DarkGrey')}() |>
{\(.) column_spec(., 90, background = 'Gray')}() |>
{\(.) column_spec(., 91, background = 'DarkGrey')}() |>
{\(.) column_spec(., 92, background = 'Gray')}() |>
{\(.) column_spec(., 93, background = 'DarkGrey')}() |>
{\(.) column_spec(., 94, background = 'Gray')}() |>
{\(.) column_spec(., 95, background = 'DarkGrey')}() |>
{\(.) column_spec(., 96, background = 'Gray')}() |>
{\(.) column_spec(., 97, background = 'DarkGrey')}() |>
{\(.) column_spec(., 98, background = 'Gray')}() |>
{\(.) column_spec(., 99, background = 'DarkGrey')}() |>
{\(.) column_spec(., 100, background = 'Gray')}() |>
{\(.) column_spec(., 101, background = 'DarkGrey')}() |>
{\(.) column_spec(., 102, background = 'Gray')}() |>
{\(.) column_spec(., 103, background = 'DarkGrey')}() |>
{\(.) column_spec(., 104, background = 'Gray')}() |>
{\(.) column_spec(., 105, background = 'DarkGrey')}() |>
{\(.) column_spec(., 106, background = 'Gray')}() |>
{\(.) column_spec(., 107, background = 'DarkGrey')}() |>
{\(.) column_spec(., 108, background = 'Gray')}() |>
{\(.) column_spec(., 109, background = 'DarkGrey')}() |>
{\(.) column_spec(., 110, background = 'Gray')}() |>
{\(.) column_spec(., 111, background = 'DarkGrey')}() |>
{\(.) column_spec(., 112, background = 'Gray')}() |>
{\(.) column_spec(., 113, background = 'DarkGrey')}() |>
{\(.) column_spec(., 114, background = 'Gray')}() |>
# {\(.) column_spec(., 12, background = 'LightGray',
# color = 'goldenrod')}() |>
{\(.) kable_styling(., bootstrap_options =
c('striped', 'hover', 'condensed', 'responsive'))}() |>
##`full_width = FALSE`是将每列设置为伸缩性自动调整宽度。
{\(.) kable_material(., full_width = FALSE)}() |>
{\(.) scroll_box(., width = '100%', fixed_thead = TRUE,
height = '490px')}()
## 绘制天下数据图表
绘图甲 <- 天下数据 |>
highchart() |>
hc_chart('line', hcaes(x = 年份, y = 钱谷, group = 天下)) |>
hc_title(text = '天下') |>
hc_subtitle(text = '钱谷')
tagList(绘图甲)
group_by
highchater::group_by
highcharter::group_by
dplyr::group_by
## 绘制天下数据图表
天下数据 %>%
dplyr::group_by(天下) %>%
e_charts(x = 年份) %>%
e_line(钱谷, smooth = TRUE) %>%
e_datazoom(
type = 'slider',
toolbox = FALSE,
bottom = -5) %>%
e_tooltip() %>%
e_title(text = '天下', subtext = '钱谷', left = 'center') %>%
e_axis_labels(x = '年份', y = '钱谷') %>%
e_x_axis(年份, axisPointer = list(show = TRUE)) %>%
e_legend(
orient = 'vertical',
type = c('scroll'),
#selectedMode = 'multiple', #https://echarts.apache.org/en/option.html#legend
#selected = list('天下'),
left = 0, top = 80) %>%
e_grid(left = 150, top = 90) %>%
#e_theme('shine') %>%
e_toolbox_feature('saveAsImage', title = '截图')
季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1.rds")
日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1
日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1
unique(日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1)
unique(日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1)
季节性自回归自动化_差分阶数0_季节性差分阶数0_zoo1200 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_zoo1200.rds")
unique(季节性自回归自动化_差分阶数0_季节性差分阶数0_zoo1200)
`自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:01:00CST` <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/1/自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:01:00CST.rds")
`自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:02:00CST` <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/1/自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:02:00CST.rds")
自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:01:00CST
`自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:01:00CST`
`自动季回归_差分阶数_0_季节性差分阶数_0_数据量1200_频率1_预测时间单位1_2018-01-02 00:02:00CST`
日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1.rds")
日内指数平滑数据_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1
季节性自回归自动化_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1
季节性自回归自动化_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_msts_数据量1200_频率1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_zoo1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_zoo1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_ts1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_ts1.rds")
getwd()
列表1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/列表1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1.rds")
季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1 <- readRDS("/home/englianhu/文档/猫城/binary.com-interview-question-data/诸子百家学府/fx/USDJPY/仓库/季节性自回归自动化_差分阶数0_季节性差分阶数0_xts_数据量1200_频率1.rds")
conflicts_prefer(Ipaper::is_empty, .quiet = TRUE)
conflicts_prefer(git2r::reset, .quiet = TRUE)
conflicts_prefer(Ipaper::llply, .quiet = TRUE)
conflicts_prefer(Ipaper::`%->%`, .quiet = TRUE)
conflicts_prefer(tibble::view, .quiet = TRUE)
conflicts_prefer(lubridate::year, .quiet = TRUE)
conflicts_prefer(gtools::permutations, .quiet = TRUE)
conflicts_prefer(tidyft::complete, .quiet = TRUE)
conflicts_prefer(tidyft::nth, .quiet = TRUE)
conflicts_prefer(tidyft::fill, .quiet = TRUE)
conflicts_prefer(tidyft::nest, .quiet = TRUE)
conflicts_prefer(tidyft::unnest, .quiet = TRUE)
conflicts_prefer(tidyft::cummean, .quiet = TRUE)
conflicts_prefer(tidyft::group_by, .quiet = TRUE)
conflicts_prefer(tidyft::distinct, .quiet = TRUE)
conflicts_prefer(tidyft::filter, .quiet = TRUE)
conflicts_prefer(tidyft::select, .quiet = TRUE)
conflicts_prefer(tidyft::rename, .quiet = TRUE)
conflicts_prefer(tidyft::count, .quiet = TRUE)
conflicts_prefer(tidyft::arrange, .quiet = TRUE)
conflicts_prefer(tidyft::summarise, .quiet = TRUE)
conflicts_prefer(tidyft::separate, .quiet = TRUE)
conflicts_prefer(tidyft::lead, .quiet = TRUE)
conflicts_prefer(tidyft::lag, .quiet = TRUE)
conflicts_prefer(tidyft::unite, .quiet = TRUE)
conflicts_prefer(tidyft::left_join, .quiet = TRUE)
conflicts_prefer(tidyft::right_join, .quiet = TRUE)
conflicts_prefer(tidyft::inner_join, .quiet = TRUE)
conflicts_prefer(tidyft::full_join, .quiet = TRUE)
conflicts_prefer(tidyft::anti_join, .quiet = TRUE)
conflicts_prefer(tidyft::semi_join, .quiet = TRUE)
conflicts_prefer(tidyft::select_dt, .quiet = TRUE)
conflicts_prefer(tidyft::transpose, .quiet = TRUE)
conflicts_prefer(tidyft::setDT, .quiet = TRUE)
conflicts_prefer(tidyft::setnames, .quiet = TRUE)
conflicts_prefer(dplyr::mutate, .quiet = TRUE)
conflicts_prefer(dplyr::collapse, .quiet = TRUE)
conflicts_prefer(lubridate::year, .quiet = TRUE)
conflicts_prefer(data.table::first, .quiet = TRUE)
conflicts_prefer(data.table::last, .quiet = TRUE)
conflicts_prefer(data.table::between, .quiet = TRUE)
conflicts_prefer(data.table::set, .quiet = TRUE)
conflicts_prefer(data.table::`:=`, .quiet = TRUE)
conflicts_prefer(hms::hms, .quiet = TRUE)
conflicts_prefer(fabletools::accuracy, .quiet = TRUE)
conflicts_prefer(base::load, .quiet = TRUE)
conflicts_prefer(base::merge, .quiet = TRUE)
save.image("~/文档/猫城/RedFlag-Linux/.RData")
rm(list = ls())
rm(list = ls()); save.image("~/文档/猫城/binary.com-interview-question/.RData")
save.image("~/文档/猫城/RedFlag-Linux/.RData")
library(readxl)
fenci <- read_excel("礼逆袭应用仓库/红旗音乐/TongJi/fenci.xls")
View(fenci)
reticulate::repl_python()
#http://music.163.com/api/song/lyric?' + 'id=' + str(song_Id) + '&lv=1&kv=1&tv=-1
library(readxl)
fenci <- read_excel("礼逆袭应用仓库/红旗音乐/TongJi/fenci.xls")
View(fenci)