This repository has been archived by the owner on Jan 11, 2024. It is now read-only.
generated from pjournal/gh-pages-quarto-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
assignment1.qmd
123 lines (85 loc) · 4.35 KB
/
assignment1.qmd
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
---
title: "Assignment 1"
format: html
editor: visual
author: "Derya Şaşmaz"
date: "2023-10-25"
---
## Who is Derya?
I'm **Derya Şaşmaz.** I'm currently working at Sigortam.net as CX & Process Developer. Data-driven decision making is the key for my role. I use data to prioritize the tasks and analyze cost-benefits for all projects.
👩💻 [My LinkedIn Profile](https://www.linkedin.com/in/deryasasmaz/)
Feel free to connect with me!
## Posit Videos
I choose **"Data Visualization and Plotting with Shiny for Python"** and "**Shiny Programming Practices"** videos. The main reason is my interest in data visualization, especially at work. After learning some about Shiny, I decided to watch the second video too.
### **Data Visualization and Plotting with Shiny for Python**
::: {style="text-align: center;"}
<iframe width="560" height="315" src="https://www.youtube.com/embed/5zJC0AB-UK8?si=YVCcu6Ft7dG1PCVN" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen>
</iframe>
:::
In the first video, there is a discussion about the development of an interactive web application using Shiny, a web application framework for R, and its integration with various data visualization tools. It covers creating interactive applications with Shiny, explaining reactive calculations, using the render plot function for data visualization, introducing its wide compatibility with different packages, and providing practical code examples for using visualization libraries within the Shiny application.
### **Shiny Programming Practices**
::: {style="text-align: center;"}
<iframe width="560" height="315" src="https://www.youtube.com/embed/B2JzHv4FOTU?si=J67nNxSbMHlNoHGc" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen>
</iframe>
:::
The second video reflects on the author's experiences building UIs using traditional event-driven methods. It mentions the concept of a "reactive graph" in frameworks like Shiny for R. He draws an analogy between functions and reactive components, explains the need for modules to be easily understandable.
## Dataset
### Netflix Movies and TV Shows
"Netflix Movies and TV Shows" is a great data to analyze. Netflix is one of the most popular media and video streaming platforms. They have over 8000 movies or tv shows available on their platform.
The dataset provides details about a wide range of movies and TV shows available on Netflix, including information about their release year, rating, duration, and more. It's a comprehensive dataset for exploring the Netflix content library.
This dataset offers an engaging and relevant way to teach data analysis, data visualization, and recommendation systems, all within the context of a popular streaming platform. I believe it allows students to work with real-world data while learning valuable data science skills.
[Dataset Kaggle Link](https://www.kaggle.com/datasets/shivamb/netflix-shows/)
## R Posts
### Data Visualization with ggplot2
This helps to create a simple scatter plot using the ggplot2 package to visualize data.
```{r}
# Load the ggplot2 library
library(ggplot2)
# Create a sample dataset
data <- data.frame(
X = c(1, 2, 3, 4, 5),
Y = c(2, 3, 1, 4, 2)
)
# Create a scatter plot
ggplot(data, aes(x = X, y = Y)) +
geom_point(shape = 19, size = 3, color = "blue") +
labs(
title = "Simple Scatter Plot",
x = "X-axis",
y = "Y-axis"
)
```
### Basic Data Frame Creation
This example shows how to create a basic data frame in R.
```{r}
# Create a basic data frame
data <- data.frame(
Name = c("Alice", "Bob", "Charlie", "David"),
Age = c(25, 30, 22, 28),
Grade = c("A", "B", "B", "A")
)
# Print the data frame
data
```
### Basic Arithmetic Operations
Some basic arithmetic operation examples with two variables.
```{r}
# Define two variables
a <- 5
b <- 3
# Addition
sum_ab <- a + b
cat("Sum of a and b: ", sum_ab, "\n")
# Subtraction
diff_ab <- a - b
cat("Difference between a and b: ", diff_ab, "\n")
# Multiplication
product_ab <- a * b
cat("Product of a and b: ", product_ab, "\n")
# Division
quotient_ab <- a / b
cat("Division of a by b: ", quotient_ab, "\n")
# Exponentiation
power_ab <- a^b
cat("a raised to the power of b: ", power_ab, "\n")
```