Hi guys,
I’ve seen this issue addressed previously, but I couldn’t understand if it’s been implemented in some ways.

I’d like to go through a GRanges object by row - or interval - (let’s say variants, or genes) and perform a function (ex. to annotate with additional metadata).
I can do that with

for (i in 1:length(variants)){
  #do something with variants[i,] data
}

but it’s quite slow.
as someone else asked in the past, something like
apply(variants, 1, myFunction) or
lapply(variants, myFunction)
would be great.
is there something like grapply? :)

Any advice?

thanks,
Francesco


	[[alternative HTML version deleted]]

