Package: comparesv
comparesvPython CSV Comparison on steriodsInstallationpip install comparesvUsagecomparesv [-h] [-v] [--enc1 ENCODING] [--enc2 ENCODING] [-i][-rm ROW_MATCH] [-cm COLUMN_MATCH] [-sm STRING_MATCH] [-ir][-ic] [-is] [-s][FILE1] [FILE2]CSV files comparisonpositional arguments:FILE1                 the first CSV fileFILE2                 the second CSV fileoptional arguments:-h, --help            show this help message and exit-v, --version         show program's version number and exit--enc1 ENCODING       encoding of the first file (default is to autodetect)--enc2 ENCODING       encoding of the second file (default is to autodetect)-i, --ignore-case     ignore case (default is case-sensitive)-rm ROW_MATCH, --row-match ROW_MATCHLogic to be used to identify the rows. Possibleoptions 'order', 'fuzzy', 'deep' (default is order)-cm COLUMN_MATCH, --column-match COLUMN_MATCHLogic to be used to identify the columns. Possibleoptions 'exact','fuzzy' (default is exact)-sm STRING_MATCH, --string-match STRING_MATCHLogic to be used to identify the columns. Possibleoptions 'exact','fuzzy' (default is exact)-ir, --include-addnl-rowsInclude added additional added rows from second file(default is false)-ic, --include-addnl-columnsInclude added additional columns from second file(default is false)-is, --include-stats  Include stats (default is false)-s, --save-output     Save output to fileExamplesScenario 1: Simple direct comparisonidfirstlastage432RoyAguilar46914JanieBowman24021GraceCopeland53708LouiseFranklin25850GertrudeCarr60vsidfirstlastage432RoyAguilar46914JanieBowman24021GraceCopeland53708LouiseFranklin25850GertrudeCarr60comparesv file1 file2Will provide:S.Noidfirstlastage1TrueTrueTrueTrue2TrueTrueTrueTrue3TrueTrueTrueTrue4TrueTrueTrueTrue5TrueTrueTrueTrueandS.Noidfirstlastage1[432]:[432][Roy]:[Roy][Aguilar]:[Aguilar][46]:[46]2[914]:[914][Janie]:[Janie][Bowman]:[Bowman][24]:[24]3[021]:[021][Grace]:[Grace][Copeland]:[Copeland][53]:[53]4[708]:[708][Louise]:[Louise][Franklin]:[Franklin][25]:[25]5[850]:[850][Gertrude]:[Gertrude][Carr]:[Carr][60]:[60]Scenario 2: Fuzzy column namesidfirstlastage of student432RoyAguilar46914JanieBowman24andidfirstlastage432RoyAguilar46914JanieBowman24comparesv file1.csv file2.csv --column-match 'fuzzy'will provideS.Noidfirstlastage1TrueTrueTrueTrue2TrueTrueTrueTrueScenario 3: Fuzzy row order - Differnt ordered textual dataidfirstlastage432RoyAguilar46914JanieBowman24021GraceCopeland53andidfirstlastage of student021GraceCopeland53432RoyAguilar46914JanieBowman24comparesv file1.csv file2.csv --column-match 'fuzzy' --row-match 'fuzzy'will provideS.Noidfirstlastage1TrueTrueTrueTrue2TrueTrueTrueTrue3TrueTrueTrueTrueScenario 3: Deep row order - Different ordered numerical datayear1year2year3year751609590930417501441763691621941563179781335225961530433571andyear1year2year3year961530433571751609590930691621941563179781335225417501441763comparesv file1.csv file2.csv --row-match 'deep'S.Noyear1year2year3year1TrueTrueTrueTrue2TrueTrueTrueTrue3TrueTrueTrueTrue4TrueTrueTrueTrue5TrueTrueTrueTrueScenario n: Unlimited options. Please explore the options belowDescriptionThe first file is considered as the source file. It will be compared against the second file. Refer the below options to finetune the way it works.Row Match (-rm)This will define the way how the rows between the files will be identified for comparisonorder- This is the default option, This will compare the rows by their position between the files. This can be used if the records in both the files are in same orderfuzzy- This will use fuzzy logic to identify the matching row on second file. This can be used if the records are not in order and most of the data aretext.deep- This will use fuzzy logic to identify the matching row on second file. This can be used if the records are not in order and it hasnumericdata. This will look for each row in file1 against all the rows in file2 to find a potential matchColumn Match (-rm)This will define the way how the columns between the files will be identified for comparisonexact- This is the default option, This will compare the columns between the files by their headers for an exact match and select it for comparison. eg. 'Age' and 'Age' columns across the files will be selected for comparison.fuzzy- This will use fuzzy logic to identify the matching column on second file. This can be used if the column headers across the files are not exactly same by somehow closer. eg. 'age' and 'age of student' columns may be selected for comparison.String Match (-sm)This will define the way how the textual data is compared.exact- This is the default option, This will compare the exact text.fuzzy- This will use fuzzy logic to find if the texts are closer to each other and identifies the match.Include Additional Rows (-ir)If the second file contains more rows than the first file, this option will enable the comparison output to include the remaining rows (uncompared ones).Include Additional Columns (-ic)If the second file contains more columns than the first file, this option will enable the comparison output to include the remaining columms.Ignore case (-i)This option will ignore the case while comparing the strings.Include Stats (-is)This option is enabled by default and it outputs the comparison stats (in percentage) on the consoleSave Output (-s)This option will save the result & values comparison in the current directory. This is enabled by default.