Displaying 4 results from an estimated 4 matches for "wind_speed".
2011 Apr 27
3
MASS fitdistr with plyr or data.table?
...t sites. I can do this in a clunky way, but
I was hoping to find a way using data.table or plyr. However, when I
try I am met with the following:
set.seed(144)
weib.dist<-rweibull(10000,shape=3,scale=8)
weib.test<-data.table(cbind(1:10,weib.dist))
names(weib.test)<-c('site','wind_speed')
fitted<-weib.test[,fitdistr(wind_speed,'weibull'),by=site]
Error in class(ans[[length(byval) + jj]]) = class(testj[[jj]]) :
invalid to set the class to matrix unless the dimension attribute is
of length 2 (was 0)
In addition: Warning messages:
1: In dweibull(x, shape, scale, lo...
2006 Mar 14
1
Ordered logistic regression in R vs in SAS
I tried the following ordered logistic regression in R:
mod1 <- polr(altitude~sp + wind_dir + wind_speed + hr, data=altioot)
But when I asked The summary of my regression I got the folloing error message:
> summary (mod1)
Re-fitting to get Hessian
Error in optim(start, fmin, gmin, method = "BFGS", hessian = Hess, ...) :
the initial value of 'vmin' is not finished.
I...
2011 Apr 23
0
MASS fitdistr call in plyr help!
...ations. The data is
a data frame with two columns: site and wind speed. I want to split
the data on site and call a function to find the shape and scale
parameters of a weibull distribution fit.
The end result is a plot with x-axis = shape and y-axis = scale.
Currently my code looks like:
fit_wind_speed<-function(x){
x<-replace(x,x<=0,0.0001)
temp<-fitdistr(na.exclude(x[,1]),"weibull")
l<-length(names(x))
for(i in 1:l){
temp[i]<-(fitdistr(na.exclude(x[,i]),"weibull"))
}
temp
}
wind_speed_wide_dataframe<-function(x){
mini<-m...
2010 Apr 17
1
Frequency table
Hello,
I'm trying to make a table like windfreq.dat in the rose diagram example of
the climatol package.
It looks like:
N NNE NE ENE E ESE SE SSE S SSW SW WSW W
WNW NW NNW
0-3 59 48 75 90 71 15 10 11 14 20 22
22 24 15 19 33
3-6 3 6 29 42 11 3 4 3 9 50
67 28