Publications by Daniel Lee

Apply Data 7

18.10.2023

knitr::opts_chunk$set(echo = TRUE) # Load package library(tidyverse) ## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ── ## ✔ dplyr 1.1.3 ✔ readr 2.1.4 ## ✔ forcats 1.0.0 ✔ stringr 1.5.0 ## ✔ ggplot2 3.4.3 ✔ tibble ...

175 sym R (7232 sym/20 pcs)

Code Along 7

18.10.2023

# Load packages # Core library(tidyverse) library(tidyquant) Goal five stocks: “SPY”, “EFA”, “IJS”, “EEM”, “AGG” from 2012-12-31 to 2017-12-31 1 Import stock prices symbols <- c("SPY", "EFA", "IJS", "EEM", "AGG") prices <- tq_get(x = symbols, get = "stock.prices", from = "2012-...

308 sym R (4339 sym/17 pcs) 3 img

DAT3100: Apply 6 - CEO Departures

18.10.2023

library(tidyverse) ## Warning: package 'tidyverse' was built under R version 4.2.3 ## Warning: package 'ggplot2' was built under R version 4.2.3 ## Warning: package 'tibble' was built under R version 4.2.3 ## Warning: package 'readr' was built under R version 4.2.3 ## Warning: package 'dplyr' was built under R version 4.2.3 ## Warning: package 'for...

126 sym R (28818 sym/52 pcs) 3 img

Code along 7

18.10.2023

# Load packages # Core library(tidyverse) library(tidyquant) Goal Collect individual returns into a portfolio by assigning a weight to each stock five stocks: “SPY”, “EFA”, “IJS”, “EEM”, “AGG” from 2012-12-31 to 2017-12-31 1 Import stock prices # Choose stocks symbols <- c("SPY", "EFA", "IJS", "EEM", "AGG") prices <- tq_get...

443 sym R (4634 sym/24 pcs) 3 img

Jason Zink - Code Along 7

18.10.2023

Tidy Data Pivoting Long to wide form table4a_long <- table4a %>% pivot_longer(cols = c(`1999`, `2000`), names_to = "year", values_to = "cases") Wide to long form table4a_long %>% pivot_wider(names_from = year, values_from = cases) ## # A tibble: 3 × 3 ## country `1999` `2000` ## ...

179 sym Python (2819 sym/15 pcs)

Apply to Data 6

12.10.2023

# Load packages # Core library(tidyverse) library(tidyquant) Goal Visualize expected returns and risk to make it easier to compare the performance of multiple assets and portfolios. Choose your stocks. from 2012-12-31 to 2017-12-31 1 Import stock prices # Choose stocks symbols <- c("AAPL", "NVDA", "ADBE", "AVGO", "AMD") # Using tq_get() ...

1023 sym R (2106 sym/9 pcs)

Document

13.10.2023

library(tidyverse) ## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ── ## ✔ dplyr 1.1.3 ✔ readr 2.1.4 ## ✔ forcats 1.0.0 ✔ stringr 1.5.0 ## ✔ ggplot2 3.4.3 ✔ tibble 3.2.1 ## ✔ lubridate 1.9.2 ✔ tidyr 1.3.0 ## ...

980 sym R (9585 sym/36 pcs) 9 img

Code along 6

13.10.2023

… title: “Code Along 6” author: “Luka Prestia” date: “2023-10-10” output: html_document editor_options: chunk_output_type: console — # Load packages # Core library(tidyverse) library(tidyquant) library(ggplot2) Goal Collect individual returns into a portfolio by assigning a weight to each stock five stocks: “SPY”, “EFA”, �...

503 sym R (3929 sym/20 pcs) 1 img

Week 8: Real World Applications 7

16.10.2023

Part 1: Recession or No Recession? Find one news article published in the last three months predicting an imminent recession and another advocating that the economy is flourishing without any signs of recession. Summarize each argument in a single paragraph, highlighting the data and evidence cited to support their claims. Please add the URL of...

1119 sym 1 tbl

DAT3100: Apply 6 - CEO Departures

16.10.2023

CEO Departures: The dataset documents the reasons for CEO departure in S&P 1500 firms from 2000 through 2018. Build a classification model to predict CEO departure (ceo_dismissal). Use the departures dataset. library(tidyverse) library(tidyquant) departures <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/mas...

2380 sym R (21058 sym/27 pcs) 7 img 4 tbl