Skip to content

Instantly share code, notes, and snippets.

@riqbal-k
Last active October 16, 2022 13:03
Show Gist options
  • Save riqbal-k/2ac62e74383c768f58039c2422c6db61 to your computer and use it in GitHub Desktop.
Save riqbal-k/2ac62e74383c768f58039c2422c6db61 to your computer and use it in GitHub Desktop.
r1
getwd() # get working directory
setwd('') # set working directory
install.packages("PerformanceAnalytics")
library (PerformanceAnalytics) # load the package
ms<-read.csv("Microsoft.csv", header=TRUE) #load Microsoft daily prices
head(ms)
sp<-read.csv("SP.csv", header=TRUE) # load S and P 500 daily prices
head(sp)
class(ms)
class(sp)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment