-
Notifications
You must be signed in to change notification settings - Fork 0
/
.Rhistory
76 lines (76 loc) · 3.21 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
library(ARTofR)
ARTofR:::ARTofR_user_interface()
ARTofR::xxx_box("For simplicity, I've removed all rows with missing values (i.e. `NaN`s in the `Depth` column & `NA`s in the `BedTemperature` column) before calculating averages. However, exploring and thinking critically about missing data is an important part of data analysis, and in a real-life scenario, you should consider the most appropriate method for handling them.")
ARTofR:::ARTofR_user_interface()
ARTofR::xxx_box1(" # For simplicity, I've removed all rows with missing values (i.e. `NaN`s in # the `Depth` column & `NA`s in the `BedTemperature` column) before # calculating averages. However, exploring and thinking critically about # missing data is an important part of data analysis, and in a real-life # scenario, you should consider the most appropriate method for handling # them. ")
?write.csv
xxx_divider1("SETUP")
#| eval: false
#| echo: true
#..........................load packages.........................
library(palmerpenguins)
library(tidyverse)
#..................practice filtering for island.................
island_df <- penguins %>%
filter(island %in% c("Dream", "Torgesen"))
#........................plot penguin data.......................
ggplot(na.omit(island_df), aes(x = flipper_length_mm, fill = species)) +
geom_histogram(alpha = 0.6, position = "identity", bins = 25) +
scale_fill_manual(values = c("Adelie" = "#FEA346", "Chinstrap" = "#B251F1", "Gentoo" = "#4BA4A4")) +
labs(x = "Flipper length (mm)", y = "Frequency",
fill = "Penguin species") +
myCustomTheme()
#............custom ggplot theme (apply to both plots)...........
myCustomTheme <- function() {
theme_light() +
theme(axis.text = element_text(size = 12),
axis.title = element_text(size = 14, face = "bold"),
legend.title = element_text(size = 14, face = "bold"),
legend.text = element_text(size = 13),
legend.position = "bottom",
panel.border = element_rect(linewidth = 0.7))
}
#........................plot penguin data.......................
ggplot(na.omit(island_df), aes(x = flipper_length_mm, fill = species)) +
geom_histogram(alpha = 0.6, position = "identity", bins = 25) +
scale_fill_manual(values = c("Adelie" = "#FEA346", "Chinstrap" = "#B251F1", "Gentoo" = "#4BA4A4")) +
labs(x = "Flipper length (mm)", y = "Frequency",
fill = "Penguin species") +
myCustomTheme()
?bc_vars_global
library(fresh)
?bc_vars_global
?bs_vars_global
?bs_vars_navbar
?bs_vars_tabs
library(shiny)
runExample(example = NA)
runExample("01_hello")
#| eval: false
#| echo: true
# load packages ----
library(palmerpenguins)
library(tidyverse)
# create scatterplot ----
ggplot(na.omit(penguins),
aes(x = flipper_length_mm, y = bill_length_mm,
color = species, shape = species)) +
geom_point() +
scale_color_manual(values = my_penguin_colors) +
scale_shape_manual(values = my_penguin_shapes) +
labs(x = "Flipper length (mm)", y = "Bill length (mm)",
color = "Penguin species", shape = "Penguin species") +
theme_minimal() +
theme(legend.position = c(0.85, 0.2),
legend.background = element_rect(color = "white"))
?icon
library(shiny)
library(shinytest2)
?testServer
library(shiny)
?textInput
?appdriver
?observe
<br>
?dir
quarto preview