facebookincubator / GeoLift

GeoLift is an end-to-end geo-experimental methodology based on Synthetic Control Methods used to measure the true incremental effect (Lift) of ad campaign.
https://facebookincubator.github.io/GeoLift/
MIT License
182 stars 55 forks source link

ROPE Analysis #83

Closed ArturoEsquerra closed 2 years ago

ArturoEsquerra commented 2 years ago

Test code:

data(GeoLift_Test)

GeoTestData_Test <- GeoDataRead(data = GeoLift_Test,
                                date_id = "date",
                                location_id = "location",
                                Y_id = "Y",
                                X = c(), #empty list as we have no covariates
                                format = "yyyy-mm-dd",
                                summary = TRUE)

GeoTest <- GeoLift(Y_id = "Y",
                   data = GeoTestData_Test,
                   locations = c("chicago", "portland"),
                   treatment_start_time = 91,
                   treatment_end_time = 105)

plot(GeoTest, type = "att")
plot(GeoTest, type = "att", post_treatment_periods = 5, ROPE = TRUE)
plot(GeoTest, type = "att", post_treatment_periods = 5, ROPE = FALSE)

plot(GeoTest, type = "Lift")
plot(GeoTest, type = "Lift", post_treatment_periods = 5)
ArturoEsquerra commented 2 years ago

@michael-khalil