dropDuplicateRows#
- lsst.ap.association.dropDuplicateRows(catalog, index, name, log)#
Index a catalog loaded from the Apdb and drop any duplicate rows.
Where several rows share an index, the first is kept exactly as the Apdb returned it and the others are discarded. The rows stay in the order the Apdb returned them.
Parameters#
- catalog
pandas.DataFrame Catalog loaded from the Apdb. Left unchanged.
- index
strorlist[str] Column or columns to index the catalog on.
- name
str Name of the catalog, for logging.
- log
logging.Logger Log to report duplicates to.
Returns#
- catalog
pandas.DataFrame A new catalog, indexed by
indexand free of duplicates.
- catalog