gold: Gold price log-returns

goldR Documentation

Gold price log-returns

Description

Gold price log-returns for the year 2023 obtained from Yahoo Finance using the quantmod R package. Code used to download, format, and save the data:

gold = quantmod::getSymbols("GC=F", src = "yahoo", auto.assign = FALSE)
gold = quantmod::dailyReturn(gold, type = "log")
gold = data.frame("date" = as.Date(zoo::index(gold)),
                  "log.returns" = as.vector(gold$daily.returns), 
                  row.names = NULL)

Format

A data frame with the following variables:

date

Date (format: yyyy-mmm-dd).

log.returns

Daily log-return.


mclustAddons documentation built on April 3, 2025, 11:19 p.m.