Skip to content
Prev 366966 / 398506 Next

beginner question: subset first entry (row) per week

new.df <- orig.df[!duplicated(df[["week"]]), ]

See ?duplicated

-- Bert
Bert Gunter

"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Thu, Feb 2, 2017 at 1:04 PM, Dagmar <Ramgad82 at gmx.net> wrote: