ML dashboard fixes
This commit is contained in:
parent
27f70afb2c
commit
b137ac688b
2 changed files with 18 additions and 18 deletions
|
@ -818,8 +818,8 @@ if (interactive()){
|
|||
### NGLViewer ####
|
||||
# Structure Viewer WebGL/NGLViewR window
|
||||
output$structure <- renderNGLVieweR({
|
||||
#ngl_gene=isolate(input$switch_target)
|
||||
ngl_gene=input$switch_target
|
||||
ngl_gene=isolate(input$switch_target)
|
||||
# ngl_gene=input$switch_target
|
||||
ngl_drug=target_map[[ngl_gene]]
|
||||
ngl_pdb_file=paste0(load_dir, "Data/", ngl_drug, '/output/depth/', ngl_gene, '_complex.pdb')
|
||||
print(ngl_pdb_file)
|
||||
|
|
32
ml/global.R
32
ml/global.R
|
@ -147,22 +147,22 @@ makeplot = function(x, # the DataFrame to plot
|
|||
y_coord_min = 0
|
||||
}
|
||||
if (display_infobox) {
|
||||
metadata=t(plot_data[1,colnames(plot_data)[colnames(plot_data) %in% metadata_cols]])
|
||||
metadata=plot_data[1,colnames(plot_data)[colnames(plot_data) %in% metadata_cols]]
|
||||
if (display_combined){
|
||||
metatext=paste0("Train/Test: ",
|
||||
metadata[1], "/", metadata[2],
|
||||
"\nTrain/Test Target Ratio: ", metadata[3], "/", metadata[4],
|
||||
"\nResampling: ", metadata[5],
|
||||
"\nFeatures: ", metadata[6],
|
||||
metadata$n_training_size, "/", metadata$n_test_size,
|
||||
"\nTrain/Test Target Ratio: ", metadata$n_trainingY_ratio, "/", metadata$n_testY_ratio,
|
||||
"\nResampling: ", metadata$resampling,
|
||||
"\nFeatures: ", metadata$n_features,
|
||||
"\nGenes Trained: ", combined_training_genes,
|
||||
"\nTest Gene: ", gene
|
||||
)
|
||||
} else {
|
||||
metatext=paste0("Train/Test: ",
|
||||
metadata[1], "/", metadata[2],
|
||||
"\nTrain/Test Target Ratio: ", metadata[3], "/", metadata[4],
|
||||
"\nResampling: ", metadata[5],
|
||||
"\nFeatures: ", metadata[6],
|
||||
metadata$n_training_size, "/", metadata$n_test_size,
|
||||
"\nTrain/Test Target Ratio: ", metadata$n_trainingY_ratio, "/", metadata$n_testY_ratio,
|
||||
"\nResampling: ", metadata$resampling,
|
||||
"\nFeatures: ", metadata$n_features,
|
||||
"\nTest Gene: ", gene
|
||||
)
|
||||
}
|
||||
|
@ -171,7 +171,7 @@ makeplot = function(x, # the DataFrame to plot
|
|||
|
||||
grob <- grobTree(textGrob(metatext,
|
||||
x=0.01,
|
||||
y=0.90,
|
||||
y=0.80,
|
||||
hjust=0,
|
||||
gp=gpar(col="black")
|
||||
)
|
||||
|
@ -192,12 +192,12 @@ makeplot = function(x, # the DataFrame to plot
|
|||
) +
|
||||
coord_cartesian(ylim = c(y_coord_min, 1)) +
|
||||
annotation_custom(grob) +
|
||||
geom_label(aes_string(label=selection),
|
||||
position=position_dodge(width = -0.75),
|
||||
#vjust = 1.5,
|
||||
alpha=0.75,
|
||||
fill="white"
|
||||
|
||||
geom_text(aes_string(label=selection),
|
||||
position=position_dodge(width = -0.75),
|
||||
vjust = -0.5,
|
||||
alpha=0.75,
|
||||
fill="white"
|
||||
|
||||
) +
|
||||
scale_color_manual(values = colour_range) +
|
||||
scale_fill_manual(values = colour_range) +
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue