removeDuplicates {nprcgenekeepr} | R Documentation |
Remove duplicate records from pedigree
Description
Part of Pedigree Curation
Usage
removeDuplicates(ped, reportErrors = FALSE)
Arguments
ped |
dataframe that is the |
reportErrors |
logical value if TRUE will scan the entire file and make a list of all errors found. The errors will be returned in a list of list where each sublist is a type of error found. |
Details
Returns an updated dataframe with duplicate rows removed.
Returns an error if the table has duplicate IDs with differing data.
Value
Pedigree object with all duplicates removed.
Examples
ped <- nprcgenekeepr::smallPed
newPed <- cbind(ped, recordStatus = rep("original", nrow(ped)))
ped1 <- removeDuplicates(newPed)
nrow(newPed)
nrow(ped1)
pedWithDups <- rbind(newPed, newPed[1:3, ])
ped2 <- removeDuplicates(pedWithDups)
nrow(pedWithDups)
nrow(ped2)
[Package nprcgenekeepr version 1.0.7 Index]