Skip to content

jbgreenh/df-compare-pl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

df compare pl

compares two polars dataframes for equality
equality in this case means that:

  • both dfs must have the same columns: column names, dtypes, number of cols

  • both dfs must have the same rows

  • if the dfs have different columns they will not be checked for a difference in rows

  • row and column order do not matter for row and column comparisons

    args:
    a: a pl.Dataframe
    b: a pl.Dataframe
    col_only: a boolean indicating whether only the columns should be checked
    write_csv: a boolean indicating whether or not to write csvs with the row differences, this is helpful when there are many row differences and the normal prints won't contain everything; defaults to False

    returns:
    True if the dataframes are equal, False if not
    prints the difference if False

About

a library for comparing two polars dataframes for equality

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages