This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:jammy | |
LABEL org.label-schema.license="GPL-2.0" \ | |
org.label-schema.vcs-url="https://github.com/rocker-org/" \ | |
org.label-schema.vendor="Rocker Project" \ | |
maintainer="Dirk Eddelbuettel <[email protected]>" | |
## Set a default user. Available via runtime flag `--user docker` | |
## Add user to 'staff' group, granting them write privileges to /usr/local/lib/R/site.library | |
## User should also have & own a home directory (for rstudio or linked volumes to work properly). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) | |
colorapp2 = function () | |
{ | |
colordot = function (r, g, b) { | |
plot(0, 0, col = grDevices::rgb(r, g, b), pch = 19, cex = 15) | |
} | |
ui = fluidPage( | |
sidebarLayout( | |
sidebarPanel( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) | |
library(imager) | |
mpath = "https://mghp.osn.xsede.org/bir190004-bucket01/BiocGeneralData/mast.jpg" | |
happ = function () { | |
ui = fluidPage( | |
sidebarLayout( | |
sidebarPanel( | |
helpText("slider for cannyEdges alpha"), | |
sliderInput("alpha", "alpha", min = 0, max = 1, step = 0.05, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#' produce an ontology_index instance from semantic sql sqlite connection | |
#' @param con DBI::dbConnect value for sqlite table | |
#' @return result of ontologyIndex::ontology_index evaluated for the labels and | |
#' parent-child relations in tables statements and edge of the semantic sql resource | |
#' @export | |
semsql_to_oi = function(con) { | |
# sqlite> select * from statements where predicate = 'rdfs:label' limit 40; | |
alltabs = DBI::dbListTables(con) | |
stopifnot(all(c("edge", "statements") %in% alltabs)) | |
labdf = dplyr::tbl(con, "statements") |> dplyr::filter(predicate == "rdfs:label") |> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stopifnot(Sys.getenv("_R_CHECK_SUGGESTS_ONLY_") == "true") | |
# these error in check on nebbiolo2 but not lconway | |
suggposs = c("AffyRNADegradation", "alabaster.spatial", "ANF", "animalcules", | |
"BDMMAcorrect", "bnbc", "CancerSubtypes", "ccrepe", "CDI", "cellscape", | |
"ClassifyR", "CNVgears", "CoGAPS", "compartmap", "CoRegNet", | |
"crisprseekplus", "DEWSeq", "DEXSeq", "DMCFB", "dpeak", "DSS", | |
"EasyCellType", "eegc", "EGSEA", "EpiCompare", "exomePeak2", | |
"farms", "FCBF", "flowMap", "FoldGO", "FScanR", "GCSscore", "GenomicFeatures", | |
"GEOmetadb", "GEOquery", "gscreend", "HelloRanges", "ILoReg", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# assumes https://github.com/biocypher/igan.git README instructions | |
# followed, docker compose up -d succeeded and localhost:7474 gives | |
# a neo4j browser interface (at localhost:7687/browser on my machine) | |
# | |
# BiocManager::install("neo4j-rstats/neo4r") | |
# want 0.1.3 | |
library(neo4r) | |
library(magrittr) | |
con <- neo4j_api$new( | |
url = "http://localhost:7474", user="", password="") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# a replacement for library() that does not print tons of messages | |
# as each package is loaded. place in .Rprofile | |
libstats = function(inisess, newsess) { | |
inibase = inisess$basePkgs # unchanging? | |
inioth = names(inisess$otherPkgs) | |
newbase = newsess$basePkgs | |
newoth = names(newsess$otherPkgs) | |
iniatt = length(unique(c(inibase,inioth))) | |
newatt = length(unique(c(newbase,newoth))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(shiny) # works with the chr22.vcf.gz in the VariantAnnotation extdata | |
library(dplyr) | |
library(DT) | |
library(VariantAnnotation) | |
library(BSgenome.Hsapiens.UCSC.hg19) | |
txdb <- TxDb.Hsapiens.UCSC.hg19.knownGene | |
ui <- fluidPage( | |
titlePanel("VCF XPLORR"), | |
numericInput("numvar", "num2chk", value = 50, min = 50, max = 500, step = 10), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# https://priyanshwarke2015-ndcs.medium.com/image-classification-with-cnn-model-in-cifar100-dataset-8d4122b75bad | |
# with user-level miniconda3 installed, use | |
# miniconda3/bin/pip install matplotlib | |
# miniconda3/bin/pip install torchvision | |
import os | |
import torch | |
import torchvision |