Displaying 3 results from an estimated 3 matches for "rate1_range".
Did you mean:
date_range
2009 Dec 21
2
Reading multiple Input Files
...y analysis is random i.e. it can be 2, can be 10 or even higher. The R-code I had written (with the guidance of R helpers obviously and I am really grateful to all of you) as of now is sort of hard coding when it comes to reading interest rates as an input e.g.
## INPUT
rate_1 = read.csv('rate1_range.csv')
rate_2 = read.csv('rate2_range.csv')
rate_3 = read.csv('rate3_range.csv')
rate_4 = read.csv('rate4_range.csv')
prob_1 = read.csv('rate1_probs.csv')
prob_2 = read.csv('rate2_probs.csv')
prob_3 = read.csv('rate3_probs.csv')
prob_...
2009 Dec 28
2
Modified R Code
...ify it for varaible number of rates.
I sincerely apologize for the inconvenience I have caused so far by asking queries. Please guide me.
Regards
Maithili
# ____________________________________________
MY ORIGINAL CODE (Actual HARD CODE)
## ONS - PPA
# INPUT
rate_1 = read.csv('rate1_range.csv')
rate_2 = read.csv('rate2_range.csv')
rate_3 = read.csv('rate3_range.csv')
rate_4 = read.csv('rate4_range.csv')
prob_1 = read.csv('rate1_probs.csv')
prob_2 = read.csv('rate2_probs.csv')
prob_3 = read.csv('rate3_probs.csv')
prob_...
2010 Feb 10
4
Readjusting the OUTPUT csv file
...e = ' ')
write.csv(data.frame(rate_combination = names3, Probability3 = ONS3[, 4]), 'prob_table3.csv', row.names = FALSE)
### ###### __________________________________________________
no_of_instances = N*(read.csv('prob_table3.csv')$Probability3)
write.csv(data.frame(rate1_range = ONS3[,1], rate2_range = ONS3[,2], rate3_range = ONS3[,3], no_of_instances), 'Final Table3.csv', row.names = FALSE)
### ###### __________________________________________________
HM3 = read.csv('Final Table3.csv')
rateA_rates=rep(c(R11,R12,R13,R14,R15),25)
rateA_rates
number...