Learn R Programming

survivoR (version 2.3.5)

filter_final_n: Filter final n

Description

Filters to the final n players e.g. the final 4.

Usage

filter_final_n(df, .final_n)

Value

A data frame filtered to only the final n

Arguments

df

Input data frame. Must have version_season

.final_n

An integer to represent the final n.

Examples

Run this code

library(survivoR)
library(dplyr)

confessionals |>
  filter_us(47) |>
  filter_final_n(6) |>
  group_by(castaway) |>
  summarise(n = sum(confessional_count))

Run the code above in your browser using DataLab