Commit 3c3a7be5 authored by Lucy McNeill's avatar Lucy McNeill
Browse files

replace instaces of file with img_file in auto_crop.R

parent 2f82501b
......@@ -39,27 +39,27 @@ auto_crop <- function(img_path, max_cell_area = 20000, min_cell_area = 7000, me
antibody3_store <- 0
## for each image that is *-dna.jpeg,
for (file in file_list){
print(file)
file_base = file
filename_path_test = paste0(img_path,"/", file)
file = filename_path_test
if(grepl("*DAPI.jpeg$", file)){
file_DAPI = file
for (img_file in file_list){
print(img_file)
file_base = img_file
filename_path_test = paste0(img_path,"/", img_file)
img_file = filename_path_test
if(grepl("*DAPI.jpeg$", img_file)){
file_DAPI = img_file
image <- readImage(file_DAPI)
img_orig_DAPI <- channel(image, "grey")
antibody3_store <- 1
}
if(grepl("*SYCP3.jpeg$", file)){
if(grepl("*SYCP3.jpeg$", img_file)){
file_dna = file
file_dna = img_file
image <- readImage(file_dna)
img_orig <- channel(2*image, "grey")
antibody1_store <- 1
}
if(grepl("*MLH3.jpeg$", file)){
file_foci = file
if(grepl("*MLH3.jpeg$", img_file)){
file_foci = img_file
image <- readImage(file_foci)
img_orig_foci <- channel(image, "gray")
# call functions: get
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment