Skip to content

Commit 02747a3

Browse files
committed
fix t-test workflow for now, on/off has to be fixed later
1 parent 1621da3 commit 02747a3

2 files changed

Lines changed: 21 additions & 20 deletions

File tree

R/Heatmap.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@ Heatmap_with_groups <- function(D,
213213
column_title_gp = grid::gpar(fontsize = textsize),
214214
...)
215215

216+
return(ht)
216217
#return(list("heatmap" = ht, "data_as_matrix" = cbind(id, data.asmatrix)))
217218
}
218219

R/workflow_ttest.R

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -227,33 +227,33 @@ workflow_ttest <- function(data_path,
227227
groups = data[["group"]])
228228

229229
grDevices::pdf(paste0(output_path, "heatmap", suffix, ".pdf"), height = plot_height, width = plot_width)
230-
graphics::plot(t_heatmap[["heatmap"]])
230+
graphics::plot(t_heatmap) # [["heatmap"]]
231231
grDevices::dev.off()
232232

233-
openxlsx::write.xlsx(cbind(data[["ID"]][candidates, ], zscore = t_heatmap[["data_as_matrix"]]), paste0(output_path, "heatmap_data", suffix, ".xlsx"), overwrite = TRUE, keepNA = TRUE)
233+
#openxlsx::write.xlsx(cbind(data[["ID"]][candidates, ], zscore = t_heatmap[["data_as_matrix"]]), paste0(output_path, "heatmap_data", suffix, ".xlsx"), overwrite = TRUE, keepNA = TRUE)
234234

235235
mess <- paste0(mess, "Heatmap made for the candidates. \n")
236236

237237

238238

239-
#### Create On-Off Heatmap ####
240-
241-
if(is.null(min_valid_values_on)){
242-
min_valid_values_on <- length(intensity_columns)
243-
}
244-
245-
t_on_off_heatmap <- calculate_onoff(D = data[["D"]],
246-
id = data[["ID"]],
247-
group = data[["group"]],
248-
max_vv_off = max_valid_values_off,
249-
min_vv_on = min_valid_values_on,
250-
protein_id_col = 1)
251-
252-
grDevices::pdf(paste0(output_path, "on_off_heatmap", suffix, ".pdf"), height = plot_height, width = plot_width)
253-
graphics::plot(t_on_off_heatmap)
254-
grDevices::dev.off()
255-
256-
mess <- paste0(mess, "On-Off-Heatmap made. \n", "There were ", sum(t_on_off_heatmap[["isonoff"]]), " on/off proteins.")
239+
# #### Create On-Off Heatmap ####
240+
#
241+
# if(is.null(min_valid_values_on)){
242+
# min_valid_values_on <- length(intensity_columns)
243+
# }
244+
#
245+
# t_on_off_heatmap <- calculate_onoff(D = data[["D"]],
246+
# id = data[["ID"]],
247+
# group = data[["group"]],
248+
# max_vv_off = max_valid_values_off,
249+
# min_vv_on = min_valid_values_on,
250+
# protein_id_col = 1)
251+
#
252+
# grDevices::pdf(paste0(output_path, "on_off_heatmap", suffix, ".pdf"), height = plot_height, width = plot_width)
253+
# graphics::plot(t_on_off_heatmap)
254+
# grDevices::dev.off()
255+
#
256+
# mess <- paste0(mess, "On-Off-Heatmap made. \n", "There were ", sum(t_on_off_heatmap[["isonoff"]]), " on/off proteins.")
257257

258258

259259

0 commit comments

Comments
 (0)