search for: levels2weeklyret

Displaying 2 results from an estimated 2 matches for "levels2weeklyret".

2004 Mar 02
2
Stuck in trying to convert repetitive code into a function
Folks, I have the following repetitive code which works correctly: A = read.table(file="junior.csv", sep=",", col.names=c("date", "l")); A$date = chron(as.character(A$date), format="m/d/y"); r.junior = levels2weeklyret(lastfriday, A$date, A$l); plot(A$date, A$l, type="l", col="red", main="Junior levels") z <- locator(1) A = read.table(file="kospi.csv", sep=",", col.names=c("date", "l")); A$date = chron(as.character(A$date), form...
2004 Mar 29
9
Aggregating frequency of irregular time series
...Consultant ajayshah at mayin.org Department of Economic Affairs http://www.mayin.org/ajayshah Ministry of Finance, New Delhi ### --------------------------------------------------------------------------- ### Function levels2WeeklyRet ### ### Purpose To convert a vector of daily levels (e.g. a stock price, an ### index, a currency) into a vector of weekly returns. ### How We focus on friday-to-friday returns. If a friday was ### not traded, we take the most-recent available price. ### We compute...