Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quick fix to get experiments to run #22

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions experiments/flights/load_data.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ using CSV
using DataFrames: DataFrame

dataset = "flights"
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv") |> DataFrame
clean_data = CSV.File("datasets/$(dataset)_clean.csv") |> DataFrame
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv", stringtype=String) |> DataFrame
clean_data = CSV.File("datasets/$(dataset)_clean.csv", stringtype=String) |> DataFrame

times_for_flight = Dict{String, Set{String}}("$fl-$field" => Set() for fl in unique(dirty_table.flight) for field in [:sched_dep_time, :sched_arr_time, :act_dep_time, :act_arr_time])
for row in eachrow(dirty_table)
Expand Down
6 changes: 3 additions & 3 deletions experiments/hospital/load_data.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ using CSV
using DataFrames: DataFrame

dataset = "hospital"
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv") |> DataFrame
clean_table = CSV.File("datasets/$(dataset)_clean.csv") |> DataFrame
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv", stringtype=String) |> DataFrame
clean_table = CSV.File("datasets/$(dataset)_clean.csv", stringtype=String) |> DataFrame

# In the dirty data, CSV.jl infers that PhoneNumber, ZipCode, and ProviderNumber
# are strings. Our PClean script also models these columns as string-valued.
Expand All @@ -16,4 +16,4 @@ clean_table[!, :ProviderNumber] = map(x -> "$x", clean_table[!, :ProviderNumber]

# Stores sets of unique observed values of each attribute.
possibilities = Dict(col => remove_missing(unique(collect(dirty_table[!, col])))
for col in propertynames(dirty_table))
for col in propertynames(dirty_table))
4 changes: 2 additions & 2 deletions experiments/rents/load_data.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ using DataFrames: DataFrame

# Load data
dataset = "rents"
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv") |> DataFrame
clean_table = CSV.File("datasets/$(dataset)_clean.csv") |> DataFrame
dirty_table = CSV.File("datasets/$(dataset)_dirty.csv", stringtype=String) |> DataFrame
clean_table = CSV.File("datasets/$(dataset)_clean.csv", stringtype=String) |> DataFrame

dirty_table[!, :CountyKey] = map(x -> "$(x[1])$(split(x)[1][end])", dirty_table[!, :County])

Expand Down