purge_by_n: Filters data groups by a minimal number of observations...

purge_by_nR Documentation

Filters data groups by a minimal number of observations (n_obs)

Description

purge_by_n replaces the data entries at group n_obs < min_n to NA.

Usage

purge_by_n(df, id, min_n = 1L, rm_allna = FALSE)

Arguments

df

The name of a primary data file. By default, it will be determined automatically after matching the types of data and analysis with an id among c("pep_seq", "pep_seq_mod", "prot_acc", "gene"). A primary file contains normalized peptide or protein data and is among c("Peptide.txt", "Peptide_pVal.txt", "Peptide_impNA_pVal.txt", "Protein.txt", "Protein_pVal.txt", "protein_impNA_pVal.txt"). For analyses require the fields of significance p-values, the df will be one of c("Peptide_pVal.txt", "Peptide_impNA_pVal.txt", "Protein_pVal.txt", "protein_impNA_pVal.txt").

id

Character string; one of pep_seq, pep_seq_mod, prot_acc and gene.

min_n

Positive integer. When calling from purgePSM, peptide entries in PSM tables with the number of identifying PSMs smaller than min_n will be replaced with NA. When calling from purgePep, protein entries in peptide tables with the number of identifying peptides smaller than min_n will be replaced with NA.


qzhang503/proteoQ documentation built on March 16, 2024, 5:27 a.m.