I have a record linkage program that does the linkage between dataset 'A' and dataset…
- User
I have a record linkage program that does the linkage between dataset 'A' and dataset 'B'. The program blocks by variable 'name' and generates all combination pairs between dataset 'A' to dataset 'B' and assigns an agreemenet weight to each pair. How to calculate the error rate knowning that in the ouptut of the program I have a record id from dataset 'A' and a record id from dataset 'B' that were not used in the matching process but if the two records ids from 'A' and 'B' are equal it means it's an actual match.
- Assistant
To calculate the error rate for your record linkage program, you can follow these steps:
Definitions
- User
data = { "match_weight": [0.0000, 4.3944, 0.0000, 4.3944, 4.3944, 4.3944, 4.3944 ], "rec_id_a": [136555, 136555, 27193,43414,19261,19664,999999 ], "rec_id_b": [136555, 136555, 27193,43414,19261,19664, 136555 ], "xname" :['W', 'W', 'J', 'M', 'D', 'M','W'] }
dfx = pd.DataFrame(data)
- Assistant
- User
Calculate f1-score and error rate using sckit learn using the dataframe dfx defined earlier
- Assistant
To calculate the F1-score and error rate using , you will need to first define your true labels and predicted labels. Given your DataFrame, we can consider records where the matches as the "true" matches.
- User
why your error rate calcultation using TP, FP ,FN differs from the error calculation using sckit-learn package?
- Assistant