Thanks Jim, that's worked
On 24 January 2012 00:49, jholtman [via R] <
ml-node+s789695n4320727...@n4.nabble.com> wrote:
> If 'idh' is the set of indices resulting from the 'split', then your
> function would probably have to look like this:
>
> myfun <- function(x){
> H.scv <- Hscv(data[x, ], pil
If 'idh' is the set of indices resulting from the 'split', then your
function would probably have to look like this:
myfun <- function(x){
H.scv <- Hscv(data[x, ], pilot = "unconstr")
KDE <- kde(data[x, ], H=H.scv, approx.cont=TRUE)
}
This is based on your original example where 'data' was the ob
Thanks Jim for your reply. I've split the dataset into indices but am now
having problem with my function. The function I need to use is in two parts:
> H.scv <- Hscv(idh, pilot = "unconstr") ## commands from the ks package
>
> KDE <- kde(idh, H=H.scv, approx.cont=TRUE)
I've tried to write the
You may not need foreach if you use the power of R and vectorize your
operations. Instead of going through the loops and extracting subsets
at each iteration, use 'split' to either split the dataframe into the
subsets, or faster, create a set of indices to access the subsets of
data:
Here is one
4 matches
Mail list logo