search for: algb

Displaying 2 results from an estimated 2 matches for "algb".

Did you mean: alg
2005 Oct 13
1
subsetting data frame using by() or tapply() or other
...e.array() or as.data.frame.list() in front of tapply() and still have the same problem. I know this can't be that unusual of a data manipulation and that someone has to have done similar things before. I want to go from something like this: LOCID POPULATION YEAR DBC 1 algb-1 A 1992 0.70451575 2 algb-1 A 1993 0.59506851 3 algb-1 A 1997 0.84837544 4 algb-1 A 1998 0.50283182 5 algb-1 A 2000 0.91242707 6 algb-2 A 1992 0.09747155 7 algb-2 A 1993 0.84772253 8 algb-2...
2005 Oct 12
2
subsetting with by() or other function??
I think I must be missing something obvious, but I'm having trouble getting a data transformation to work on groupings of data within a data frame (csss3) as defined by 2 factors (population, locid). The data are sorted by year within locid within population and I want to lag another variable (dbc), i.e, shift them down by 1 row replacing the first row with NA, within groups defined by