2007/10/15, Petr PIKAL <petr.pikal@precheza.cz>:
>
> Hi
>
>
> Well, let us put it another way. Do you want for each unique combination
> of Hole and Feature to subtract a value from one data frame, let us call
> it nom from another data frame, let us call it raw? If yes I assume you
> have exactly same number of unique combinations of Hole and Feature values
> in both datasets.
>
> In that case you can use such for cycle (although there can be other finer
> solutions)
>
> for (i in 1:no.of.unique.levels) {
> selection <- interaction(raw$hole, raw$feature) %in% interaction(nom$hole,
> nom$feature)[1]
> raw[selection,"value"] <- raw[selection,"value"]-nom[i,"value"]
> }
>

I had to move on with the project and did a ruby script out side that put
the right values in the rawdata.

But I will surely return to look at this solution.

I question in the non table the combinations of Feature and Hole are unique
is it possible to calculate this on the fly in R?



-- 
Klaus F. Østergaard, <farremosen(at)gmail dot com>

	[[alternative HTML version deleted]]

