Skip to content

Instantly share code, notes, and snippets.

View wleoncio's full-sized avatar

Waldir Leoncio wleoncio

  • University of Oslo
  • Oslo
View GitHub Profile
@wleoncio
wleoncio / issue50.md
Created April 24, 2024 13:04
Fix to issue #50
# Adapted from https://github.com/tmatta/lsasim/issues/50#issue-2254039296

# Package, Data and subset
remotes::install_github("tmatta/lsasim", "issue-50")
#> Using GitHub PAT from the git credential store.
#> Skipping install of 'lsasim' from a github remote, the SHA1 (28b71cf3) has not changed since last install.
#>   Use `force = TRUE` to force installation
library(lsasim)
#> This is lsasim 2.1.4-1713963651
@wleoncio
wleoncio / reprex.md
Created April 22, 2024 08:34
Issue 50 lsasim
# Setup
remotes::install_github("tmatta/lsasim", "issue-50")
#> Using GitHub PAT from the git credential store.
#> Downloading GitHub repo tmatta/lsasim@issue-50
#> 
#> ── R CMD build ─────────────────────────────────────────────────────────────────
#> * checking for file ‘/tmp/RtmpCKm8ak/remotes9c8f72a0c9f7/tmatta-lsasim-940c83a/DESCRIPTION’ ... OK
#> * preparing ‘lsasim’:
#> * checking DESCRIPTION meta-information ... OK
@wleoncio
wleoncio / test.R
Created March 20, 2024 10:32
Reducing calls to `solve()`
# Loading package ==============================================================
library("MADMMplasso")
message(paste("MADMMplasso version", packageVersion("MADMMplasso")))
# Loading data =================================================================
CRC_data <- readRDS("aux/CRC_data_300.rds") # change this manually, I won't bother with commandArgs()
X23 <- CRC_data$x
# log2 transfermation f or the expression levels
X1 <- (X23)
@wleoncio
wleoncio / issue-35.md
Created March 11, 2024 11:18
MADMMplasso issue 35
# Setup ========================================================================
rm(list = ls())
devtools::install_github("ocbe-uio/MADMMplasso", force = TRUE)
#> Downloading GitHub repo ocbe-uio/MADMMplasso@HEAD
#> 
#> ── R CMD build ─────────────────────────────────────────────────────────────────
#> * checking for file ‘/tmp/Rtmpr2fzD2/remotes149907717ef58/ocbe-uio-MADMMplasso-9896eeb/DESCRIPTION’ ... OK
#> * preparing ‘MADMMplasso’:
#> * checking DESCRIPTION meta-information ... OK
@wleoncio
wleoncio / issue-13.R
Last active March 11, 2024 12:56
permChacko issue #13
# Simulations to address https://github.com/ocbe-uio/permChacko/issues/13
# Setup =================================================================
remotes::install_github("ocbe-uio/permChacko@issue-13")
runs <- 1000L
results <- matrix(
NA, nrow = runs, ncol = 6L,
dimnames = list(
"run" = seq_len(runs),
"p_values" = c(
@wleoncio
wleoncio / log-ubuntu-2024-01-23.md
Last active January 23, 2024 11:28
BayesMallows Valgrind tests

Input

R CMD check --use-valgrind --no-build-vignettes --no-manuals BayesMallows_2.0.1.tar.gz

Note: use --no-manual instead of --use-manuals (invalid option) next time!

Output

Building cellmigRation vignettes
--- re-building ‘cellmigRation.Rmd’ using rmarkdown
Bioconductor
version
3.12
(BiocManager
1.30.10), R
4.0.4
(2021-02-15)
Installing
@wleoncio
wleoncio / issue40-sinan.md
Created February 8, 2021 08:45
Example for issue #40

Assumptions that make code work

library(lsasim)
n_items <- 30
testInstallation:
@echo -e "If you can see this, Make has been installed successfully"
---
title: "Title"
author: Waldir Leoncio
institute: "Oslo Centre for Biostatistics and Epidemiology"
date: "2020-09-11"
output:
xaringan::moon_reader:
nature:
highlightLanguage: r
highlightLines: true