Package picard.pedigree
Class PedFile
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,,PedFile.PedTrio> NavigableMap<String,,PedFile.PedTrio> SequencedMap<String,,PedFile.PedTrio> SortedMap<String,PedFile.PedTrio>
Represents a .ped file of family information as documented here:
http://pngu.mgh.harvard.edu/~purcell/plink/data.shtml
Stores the information in memory as a map of individualId -> Pedigree information for that individual
- See Also:
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K, V> -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(PedFile.PedTrio trio) Adds a trio to the PedFile keyed by the individual id.static PedFileAttempts to read a pedigree file into memory.static PedFilefromSexMap(Map<String, Sex> sampleSexes) Function that accepts a map from sample-name to its sex and creates a PEDFile documenting the sexes.Scans through the pedigrees and removes all entries that do not have both paternal and maternal ids set.voidWrites a set of pedigrees out to disk.Methods inherited from class java.util.TreeMap
ceilingEntry, ceilingKey, clear, clone, comparator, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, descendingKeySet, descendingMap, entrySet, firstEntry, firstKey, floorEntry, floorKey, forEach, get, headMap, headMap, higherEntry, higherKey, keySet, lastEntry, lastKey, lowerEntry, lowerKey, merge, navigableKeySet, pollFirstEntry, pollLastEntry, put, putAll, putFirst, putIfAbsent, putLast, remove, replace, replace, replaceAll, size, subMap, subMap, tailMap, tailMap, valuesMethods inherited from class java.util.AbstractMap
equals, hashCode, isEmpty, toStringMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.NavigableMap
reversedMethods inherited from interface java.util.SequencedMap
sequencedEntrySet, sequencedKeySet, sequencedValues
-
Field Details
-
NO_PHENO
-
UNKNOWN_SEX
-
-
Constructor Details
-
PedFile
public PedFile(boolean isTabMode)
-
-
Method Details
-
add
Adds a trio to the PedFile keyed by the individual id. -
write
Writes a set of pedigrees out to disk. -
fromFile
Attempts to read a pedigree file into memory. -
removeIncompleteTrios
Scans through the pedigrees and removes all entries that do not have both paternal and maternal ids set. -
fromSexMap
Function that accepts a map from sample-name to its sex and creates a PEDFile documenting the sexes.- Parameters:
sampleSexes- a map from sample-name to its sex- Returns:
- a PedFile object that contains data.
-