Publications by 111078517

[Portfolio] The effect between pro-feminist and daughters

16.03.2023

Hi there! Welcome to my data visualization land. Today I will use the data about judges and the number of children they have to do the pro-feminist analysis. Import Data and observe it. judges <- read.csv("C:/R-language/PBA/judges.csv",header = TRUE) #install.packages("crosstable") library(crosstable) ## Warning: 套件 'crosstable' 是用 R �...

1932 sym R (3840 sym/27 pcs) 4 img

[Portfolio] Salary discrimination analysis

16.03.2023

Hi there! Welcome to my data visualization land. ^^ Today I will use the data to discuss whether there is discrimination against female employees in terms of salary. Import and Preprocess Data data1 <- data.table::fread("C:/R-language/PBA/banksalary.csv") require(tidyverse) ## 載入需要的套件:tidyverse ## Warning: 套件 'tidyverse' 是...

4355 sym 3 img

[Portfolio] Data visualization on the concentration of PM 2.5

15.03.2023

Hi there! Welcome to my data visualization land. Today I will use the data about PM 2.5 to do the data exploration. 1) Import and Preprocess Data classes <- c("character","character","character","character","character","numeric","numeric","numeric","numeric","numeric","numeric","numeric") data99 <- read.csv(url("https://bit.ly/3c4AHbL"),header =...

2341 sym R (8897 sym/43 pcs) 2 img

Standardize data and estimate the population

12.03.2023

Question 1 a) Create a normal distribution (mean=940, sd=190) and standardize it (let’s call it rnorm_std) d1 <- rnorm(n=500, mean=940, sd=190) rnorm_std <- (d1-mean(d1))/sd(d1) a-i) What should we expect the mean and standard deviation of rnorm_std to be, and why? mean(rnorm_std);sd(rnorm_std) ## [1] -1.965709e-16 ## [1] 1 We should expect ...

6459 sym R (2967 sym/46 pcs) 9 img

Distribution & binwidth concept

27.02.2023

This is distribution 1: # Three normally distributed data sets d1 <- rnorm(n=500, mean=15, sd=5) d2 <- rnorm(n=200, mean=30, sd=5) d3 <- rnorm(n=100, mean=45, sd=5) # Combining them into a composite dataset d123 <- c(d1, d2, d3) # Let’s plot the density function of d123 plot(density(d123), col="blue", lwd=2, main = "Distribution 1...

3453 sym 4 img

viewing data

19.02.2023

1.What is the 5th element in the original list of ages? data1 <- data.table::fread("C:/R-language/BACS/customers.txt") data1[5] ## age ## 1: 45 2.What is the fifth lowest age? library(dplyr) ## ## 載入套件:'dplyr' ## 下列物件被遮斷自 'package:stats': ## ## filter, lag ## 下列物件被遮斷自 'package:base': ## #...

597 sym R (912 sym/23 pcs) 3 img

Online Retail analysis

11.01.2023

1) Import and Examine the Data a) Import the CSV file into R using fread() and take a look at the data (e.g., dim, head, summary, etc.) require(data.table) ## 載入需要的套件:data.table data1 <- data.table::fread("C:/R-language/PBA/onlineRetail.csv") require(tidyverse) ## 載入需要的套件:tidyverse ## Warning: 套件 'tidyverse'...

4944 sym Python (24028 sym/63 pcs) 5 img 1 tbl

Document

25.10.2022

My main data set:data2 is in the data between 2011/7-2011/8, and the type of InvoiceDate was transformed to Date class. #(a)讀取資料 data1 <- read.csv("C:/R-language/class/online_retail.csv") #(b)轉日期格式 install.packages("lubridate") ## 將程式套件安載入 'C:/Users/Tsai/AppData/Local/R/win-library/4.2' ## (因為 'lib' 沒...

1567 sym R (4384 sym/36 pcs)

Assignment2

22.11.2022

1) Import and Preprocess Data First, import the datasets using the following links 1) “https://bit.ly/3c4AHbL” for 1999 data, and 2) “https://bit.ly/3nZicL2” for 2012 data using the data.table package. p.s., set colClasses of the first 5 variables to “character” and the rest of it to “numeric.” classes <- c("character","chara...

4203 sym R (8086 sym/33 pcs) 2 img

Extra Credit_exercise 2

02.12.2022

Question 1 1.How many judges are in this data set? 2.What proportion of the judges are men? 3.Is the party composition different for male and female judges? judges <- read.csv("C:/R-language/PBA/judges.csv",header = TRUE) #install.packages("crosstable") library(crosstable) ## Warning: 套件 'crosstable' 是用 R 版本 4.2.2 來建造的 c...

2591 sym R (3724 sym/26 pcs) 3 img