Browse code

Code cleanup.

Robert Ivánek authored on 06/01/2022 19:52:50
Showing 3 changed files

... ...
@@ -20,7 +20,7 @@ Description: Genomic data analyses requires integrated visualization
20 20
     package. This results in genomic information plotted together with
21 21
     your data.
22 22
 Depends:
23
-    R (>= 4.0),
23
+    R (>= 4.2),
24 24
     methods,
25 25
     S4Vectors (>= 0.9.25),
26 26
     IRanges (>= 1.99.18),
... ...
@@ -1877,7 +1877,7 @@ IdeogramTrack <- function(chromosome = NULL, genome, name = NULL, bands = NULL,
1877 1877
             })
1878 1878
             out <- getTable(query)
1879 1879
             if (all(c("chrom", "size") %in% colnames(out))) {
1880
-                out <- data.frame(chrom = out$chrom, chromStart = 0, chromEnd = out$size, name = "", gieStain = "gneg", stringsAsFactors = F)
1880
+                out <- data.frame(chrom = out$chrom, chromStart = 0, chromEnd = out$size, name = "", gieStain = "gneg", stringsAsFactors = FALSE)
1881 1881
             }
1882 1882
             out
1883 1883
         }), env, cenv)
... ...
@@ -2102,6 +2102,7 @@ setMethod("drawGD", signature("AnnotationTrack"), function(GdObject, minBase, ma
2102 2102
         }
2103 2103
         ## Plotting of the item labels
2104 2104
         if (.dpOrDefault(GdObject, "showFeatureId", FALSE)) {
2105
+            #grid.text(str2expression(box$text), box$textX, box$textY,
2105 2106
             grid.text(box$text, box$textX, box$textY,
2106 2107
                 rot = rotation, gp = .fontGp(GdObject, subtype = "item"),
2107 2108
                 default.units = "native", just = c("center", "center")
... ...
@@ -2377,13 +2378,13 @@ setMethod("drawGD", signature("AlignmentsTrack"), function(GdObject, minBase, ma
2377 2378
             )
2378 2379
             ## print the number of reads together with the connecting lines (currently no scaling/resolution)
2379 2380
             if (sashNumbers) {
2380
-                grid.rect(sash$x[c(F, T, F)], -sash$y[c(F, T, F)],
2381
+                grid.rect(sash$x[c(FALSE, TRUE, FALSE)], -sash$y[c(FALSE, TRUE, FALSE)],
2381 2382
                     width = convertUnit(stringWidth(sash$score) * 1.5, "inches"),
2382 2383
                     height = convertUnit(stringHeight(sash$score) * 1.5, "inches"),
2383 2384
                     default.units = "native", gp = gpar(col = gp$col, fill = gp$fill)
2384 2385
                 )
2385 2386
                 grid.text(
2386
-                    label = sash$score, sash$x[c(F, T, F)], -sash$y[c(F, T, F)],
2387
+                    label = sash$score, sash$x[c(FALSE, TRUE, FALSE)], -sash$y[c(FALSE, TRUE, FALSE)],
2387 2388
                     default.units = "native", gp = gpar(col = gp$col)
2388 2389
                 )
2389 2390
             }