search for: wash2005fm10feb

Displaying 1 result from an estimated 1 matches for "wash2005fm10feb".

2006 Oct 20
1
How to evaluate a Variable Name?
...am doing a regression by month as follows: # FM10 Regression by Month # Plot 12 Month of OFM10, FFM10 for(i in 1:12) { Temp <- subset (Wash2005, MM == i) assign( paste('Wash2005FM10', strtrim(month.name[i],3), sep=""),lm(Temp$FM10.1 ~ Temp$FM10)) } Wash2005FM10Jan, Wash2005FM10Feb, etc holds the regression results for each month. Now, I want to sum up the residuals of all the 12 regression. How can I do that in a loop? For (i in 1:12){ Temp <- paste('sum(Wash2005FM10', strtrim(month.name[i],3), '$residual**2)',sep="") } Temp will giv...