Skip to contents

This function calculates the counts of distinct records, records imported, and unique records for each database source. It combines these counts into one dataframe and calculates several ratios and percentages related to the unique and distinct counts. It also calculates the total for each count type.

Usage

calculate_record_counts(unique_citations, citations, n_unique, db_colname)

Arguments

unique_citations

Dataframe. The dataframe for calculating distinct records count.

citations

Dataframe. The dataframe for calculating records imported count.

n_unique

Dataframe. The dataframe for calculating unique records count.

db_colname

Character. The name of the column containing the database source information.

Value

A dataframe with counts of distinct records, imported records, and unique records for each source, including total counts and several calculated ratios and percentages.