Skip to content

Commit

Permalink
BUG: Only the first plate has the controls!
Browse files Browse the repository at this point in the history
  • Loading branch information
pan14001 committed Jan 18, 2017
1 parent 76755f4 commit 5ca7c4d
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions analysis-only_overlap.R
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,15 @@ images <- dbReadTable(con, "Per_Image") %>% setNames(tolower(names(.)))

## Create well summary from images and cells. `imagenumber` is a
## primary key.
wells <- merge(cells, select(images, imagenumber, image_metadata_well)) %>%
wells <- merge(cells, select(images, imagenumber, image_metadata_well,
image_metadata_plate)) %>%
replace_na(list(ect_classify_coloc = 0)) %>%
group_by(image_metadata_well) %>%
group_by(image_metadata_well, image_metadata_plate) %>%
summarise(n = n(), n_coloc = sum(ect_classify_coloc))

# Check the controls.
controls <- filter(wells, image_metadata_well %in% wells_control) %>%
controls <- filter(wells,
image_metadata_well %in% wells_control,
image_metadata_plate == "160415_015529-V") %>%
mutate(coloc = n_coloc / n)
print(controls)

0 comments on commit 5ca7c4d

Please sign in to comment.