Publications by Jack Tortolani

Code Along 12

20.11.2024

# 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”, �...

657 sym R (15674 sym/23 pcs) 2 img

Code Along 12

19.11.2024

# 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”, �...

595 sym R (7947 sym/17 pcs)

Code Along 11

18.11.2024

# Load packages # Core library(tidyverse) library(tidyquant) library(nycflights13) Functions When Should you Write a Function? # For reproducible for Work set.seed(1234) # Create a Data Frame df <- tibble::tibble( a = rnorm(10), b = rnorm(10), c = rnorm(10), d = rnorm(10) ) # Rescale each Column df$a <- (df$a - min(df$a, na...

270 sym R (2596 sym/26 pcs)

Apply 10

13.11.2024

# Load packages # Core library(tidyverse) library(tidyquant) Goal Calculate and visualize your portfolio’s beta. Choose your stocks and the baseline market. from 2012-12-31 to present 1 Import stock prices symbols <- c("XOM", "QQQ", "SPY", "TSLA","CGC") prices <- tq_get(x = symbols, get = "stock.prices", ...

1238 sym R (2760 sym/16 pcs) 1 img

Apply 9

13.11.2024

# 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("XOM", "QQQ", "SPY", "TSLA","CGC") prices <- tq_get(x = symbols, ...

974 sym R (3870 sym/16 pcs) 1 img

Code Along 10

13.11.2024

# 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 symbols <- c("SPY", "EFA", "IJS", "EEM", "AGG") prices <- tq_get(x = symbols...

330 sym R (3233 sym/17 pcs) 2 img

Code Along 9

04.11.2024

# 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 symbols <- c("SPY", "EFA", "IJS", "EEM", "AGG") prices <- tq_get(x = symbols...

437 sym R (6333 sym/20 pcs) 3 img

Apply 8

04.11.2024

# Load packages # Core library(tidyverse) library(tidyquant) Goal Visualize and examine changes in the underlying trend in the downside risk of your portfolio in terms of kurtosis. Choose your stocks. from 2012-12-31 to present 1 Import stock prices symbols <- c("XOM", "QQQ", "SPY", "TSLA","CGC") prices <- tq_get(x = symbols, ...

1232 sym R (3026 sym/14 pcs) 1 img

Code Along 8

30.10.2024

# 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 symbols <- c("SPY", "EFA", "IJS", "EEM", "AGG") prices <- tq_get(x = symbols...

430 sym R (3995 sym/18 pcs) 3 img

Apply 7

23.10.2024

# Load packages # Core library(tidyverse) library(tidyquant) Goal Visualize and compare skewness of your portfolio and its assets. Choose your stocks. from 2012-12-31 to 2017-12-31 1 Import stock prices symbols <- c("XOM", "QQQ", "SPY", "TSLA","CGC") prices <- tq_get(x = symbols, get = "stock.prices", fro...

989 sym R (4344 sym/20 pcs) 3 img