⚡ Adds script to convert to csv
This commit is contained in:
parent
505b4eeb55
commit
2ec2a533b2
3
.gitignore
vendored
3
.gitignore
vendored
@ -8,3 +8,6 @@ __pycache__/
|
|||||||
*.zip
|
*.zip
|
||||||
*.csv
|
*.csv
|
||||||
*.npy
|
*.npy
|
||||||
|
|
||||||
|
*.jasp
|
||||||
|
*.txt
|
||||||
|
7
to-csv.py
Normal file
7
to-csv.py
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
import numpy as np
|
||||||
|
import pandas as pd
|
||||||
|
|
||||||
|
arr = np.load("clean.npy")
|
||||||
|
df = pd.DataFrame(arr)
|
||||||
|
df.columns = ["grade", "sex", "average grade", "math grade", "slovak grade", "english grade", "ses", "occupation", "living situation", "commute length", "sleep", "absence"]
|
||||||
|
df.to_csv("clean.csv")
|
Loading…
x
Reference in New Issue
Block a user