I'm trying to redirect the output to a file by using the write.csv statement. I have 14 different output files, here's the code:
trackfilenums=1:14
for (i in trackfilenums){
calculations etc
write.csv(max.hsi, 'Index.csv', row.names=F)
}
I want to label the output csv files as, 'Index_1.csv', 'Index_2.csv', etc.
How can I do this?