Help with "For" instruction
You need to swap the get and paste commands - paste() creates the string filename that get() acts on. As already explained, using a list is much nicer. Sarah 2011/1/4 Andr? Dias <diasandre at gmail.com>:
Hi
I was doing
for (i in 1:length(database))
assign(paste("distancematrix",i,sep=""), dist(paste(get("database", i,
sep="")))))
but i really did not know what I was doing. I will try?your way. But I still
don't understnad how the get function works.
What woud be more r-ish then get() ?
thanks
ADias
Sarah Goslee http://www.functionaldiversity.org