Publications by Daniel Lee
Code Along 12
# Load packages # Core library(tidyverse) library(tidyquant) library(readr) # Time series library(lubridate) library(tibbletime) # modeling library(broom) Goal Examine how each asset contributes to portfolio standard deviation. This is to ensure that our risk is not concentrated in any one asset. five stocks: “SPY”, “EFA”, �...
612 sym R (14562 sym/30 pcs) 4 img
Apply Data 12
# Load packages # Core library(tidyverse) library(tidyquant) Goal Examine how each asset contributes to portfolio standard deviation. This is to ensure that our risk is not concentrated in any one asset. 1 Import stock prices Choose your stocks from 2012-12-31 to present. symbols <- c("MCD", "ISRG", "KHC", "FIS", "GOOG") prices <- tq_get(...
1084 sym R (13515 sym/20 pcs) 1 img
Apply Data 9
# Load packages # Core library(tidyverse) library(tidyquant) Goal Visualize and examine changes in the underlying trend in the performance of your portfolio in terms of Sharpe Ratio. Choose your stocks. from 2012-12-31 to present 1 Import stock prices symbols <- c("MCD", "ISRG", "KHC", "FIS", "GOOG") prices <- tq_get(x = symbols, ...
1239 sym R (3888 sym/16 pcs) 1 img
Apply it 12
# Load packages # Core library(tidyverse) library(tidyquant) library(broom) library(lubridate) library(tibbletime) Goal Examine how each asset contributes to portfolio standard deviation. This is to ensure that our risk is not concentrated in any one asset. 1 Import stock prices Choose your stocks from 2012-12-31 to present. symbols <- c...
794 sym R (16933 sym/20 pcs) 2 img
code along 12 DA
# Load packages # Core library(tidyverse) library(nycflights13) library(lubridate) Ch20 Vectors Introduction Vector basics Important types of automic vector Using automic vectors sample(10) + 10 ## [1] 14 19 13 16 15 17 11 12 18 20 1:10 + 1:2 ## [1] 2 4 4 6 6 8 8 10 10 12 1:10 + 1:3 ## [1] 2 4 6 5 7 9 8 10 12 11 data.frame(a ...
327 sym R (2135 sym/52 pcs)
Apply 12
# Load packages # Core library(tidyverse) library(tidyquant) Goal Examine how each asset contributes to portfolio standard deviation. This is to ensure that our risk is not concentrated in any one asset. 1 Import stock prices Choose your stocks from 2012-12-31 to present. symbol <- c("JNJ", "TSLA", "XOM", "COST", "PLUG") prices <- tq_get(x = sy...
948 sym R (14218 sym/9 pcs) 1 img
Apply 11 FA
Import your data data(flights) flights %>% skimr::skim() Data summary Name Piped data Number of rows 336776 Number of columns 19 _______________________ Column type frequency: character 4 numeric 14 POSIXct 1 ________________________ Group variables None Variable type: character skim_variable n_missing complete_rate min max empty n_un...
436 sym Python (4187 sym/27 pcs) 4 tbl
CodeAlong12
# Load packages # Core library(tidyverse) library(tidyquant) library(readr) # Time series library(lubridate) library(tibbletime) # modeling library(broom) Goal Examine how each asset contributes to portfolio standard deviation. This is to ensure that our risk is not concentrated in any one asset. five stocks: “SPY”, “EFA”, �...
603 sym R (15659 sym/23 pcs) 2 img
Apply 11 DA
Import your data data(flights) flights %>% skimr::skim() Data summary Name Piped data Number of rows 336776 Number of columns 19 _______________________ Column type frequency: character 4 numeric 14 POSIXct 1 ________________________ Group variables None Variable type: character skim_variable n_missing complete_rate min max empty n_un...
419 sym 4 tbl