Displaying 4 results from an estimated 4 matches for "model10".
Did you mean:
model1
2010 Sep 28
0
the arima()-function and AICc
...832, 6.896694, 7.004967, 7.065750,
7.139447, 7.227818, 7.274945, 7.333097, 7.350763, 7.404271, 7.426247,
7.394454, 7.303650, 7.176984, 7.170972, 7.113736, 7.154326, 7.136678,
7.103826, 7.146775, 7.084247, 7.016302, 6.784539, 6.705846, 6.709989,
6.851557, 6.973064, 7.232223)
## The AR(1) Model
model10<-arima(X,order=c(1,0,0),include.mean=T)
mu<-model10[[1]][[2]]
a<-model10[[1]][[1]]
## Get the fitted values and residuals of the arima(1,0,0)-model
fitted<-vector(mode="numeric")
E<-vector(mode="numeric")
for (i in 2:30){
fitted[i]<-a*(X[i-1]-mu)+mu
E[i]<...
2008 Sep 05
2
using nls to fit a curve to data
Hi,
I am trying to fit a curve to data. My command line is:
model10=nls(offspring~((A*c^k)/gamma(k))*((degdays-alpha)^(k-1))*exp(-c*(degdays-alpha)),
start=list(A=30,k=2,c=.018,alpha=131))
I get the error message:
Error in numericDeriv(form[[3]], names(ind), env) :
Missing value or an infinity produced when evaluating the model
In addition: Warning messa...
2010 Oct 03
5
How to iterate through different arguments?
...l line = lm(y~x1) and I want to use a for loop to change the
number of explanatory variables, how would I do this?
So for example I want to store the model objects in a list.
model1 = lm(y~x1)
model2 = lm(y~x1+x2)
model3 = lm(y~x1+x2+x3)
model4 = lm(y~x1+x2+x3+x4)
model5 = lm(y~x1+x2+x3+x4+x5)...
model10.
model_function = function(x){
for(i in 1:x) {
}
If x =1, then the list will only add model1. If x =2, then the list will add
both model1 and model2. If x=3, then the list will add model1 model 2 and
model3 and so on. How do I translate this into code?
--
View this message in context: http://r.7...
2009 Feb 02
0
Using Information from the Stats4 package in base envir
...y into a single vector
data1 = data.frame(resp1, x12) #Data frame for kmeans
cluster1 = kmeans(data1, 2, nstart=25)$cluster #Obtain cluster labels
data1 = data.frame(data1 ,cluster1)#Cluster labels in third column
data10 = subset(data1, cluster1==1)
data11 = subset(data1, cluster1==2)
model10 = lm(resp1 ~ x12, data10)#It works using the subset data frame
model1 = lm(resp1 ~ x12, cluster1 == 1, data1); #Gives the following error
Error in eval(expr, envir, enclos) : invalid 'envir' argument