Skip to content

Commit

Permalink
Merge pull request #26 from UBC-MDS/update_summary_for_readme
Browse files Browse the repository at this point in the history
Update summary for readme
  • Loading branch information
jessiezhang24 authored Jan 23, 2025
2 parents 0a53a4a + 1db68b6 commit bba8941
Showing 1 changed file with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,21 +31,25 @@ $ pip install pyeda
from pyeda.check_csv import check_csv
from pyeda.pymissing_values_summary import missing_values_summary
from pyeda.data_summary import get_summary_statistics

# Check if the given data file is in csv format
```
#### Check if the given data file is in csv format
```python
data_file_path = "docs/sample_data.csv" # path to your data file
if not check_csv(data_file_path):
raise TypeError("The given file is not in CSV format. Please check your data file.")

# Check if the data file has any missing values
```
#### Check if the data file has any missing values
```python
df = pd.read_csv(data_file_path)

missing_summary = missing_values_summary(df)
print("Missing Values Summary:")
print(missing_summary)


# Get data summary
```
#### Get the data summary for either all columns or the specified columns of our dataset
```python
get_summary_statistics(df)
get_summary_statistics(df, col=["numeric", "categorical"])
```

## Contributing
Expand Down

0 comments on commit bba8941

Please sign in to comment.