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
| # Sampling frequency and audio length | |
| freq <- 400 | |
| duration <- 5 | |
| # radian constant for sin/cos | |
| tau <- 2*pi | |
| # Generate a composite signal (4, 6, 9 hz) | |
| x <- seq(0, duration, length.out = freq*duration) | |
| y <- |
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 simple libpng example program | |
| * http://zarb.org/~gc/html/libpng.html | |
| * | |
| * Modified by Yoshimasa Niwa to make it much simpler | |
| * and support all defined color_type. | |
| * | |
| * To build, use the next instruction on OS X. | |
| * $ brew install libpng | |
| * $ clang -lz -lpng15 libpng_test.c |
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 ghcr.io/r-lib/rig/ubuntu-24.04-devel | |
| RUN echo "R_PLATFORM_PKGTYPE=linux.binary.noble-$(arch)" >> "$HOME/.Renviron" | |
| RUN R -e "print(.Platform$pkgType)" | |
| RUN R -e "install.packages('tidyverse', repos = 'https://cran.r-universe.dev')" | |
| RUN R -e "library(tidyverse)" |
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
| * installing to library ‘/home/hornik/tmp/R.check/r-devel-clang/Work/build/Packages’ | |
| * installing *source* package ‘opencv’ ... | |
| ** this is package ‘opencv’ version ‘0.5.1’ | |
| ** package ‘opencv’ successfully unpacked and MD5 sums checked | |
| ** using staged installation | |
| This is pkg-config 1.8.1 | |
| Found pkg-config cflags and libs! | |
| Using PKG_CFLAGS=-I/usr/include/opencv4 -D_DATA_PREFIX=/usr | |
| Using PKG_LIBS=-lopencv_stitching -lopencv_alphamat -lopencv_aruco -lopencv_bgsegm -lopencv_bioinspired -lopencv_ccalib -lopencv_cvv -lopencv_dnn_objdetect -lopencv_dnn_superres -lopencv_dpm -lopencv_face -lopencv_freetype -lopencv_fuzzy -lopencv_hdf -lopencv_hfs -lopencv_img_hash -lopencv_intensity_transform -lopencv_line_descriptor -lopencv_mcc -lopencv_quality -lopencv_rapid -lopencv_reg -lopencv_rgbd -lopencv_saliency -lopencv_shape -lopencv_signal -lopencv_stereo -lopencv_structured_light -lopencv_phase_unwrapping -lopencv_superres -lopencv_optflow -lopencv_surface_matching -lopencv_tracking -lopencv_highgui -lopencv_datasets - |
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
| # We use Ubuntu 14.04 to build a native gcc for win32 with multilib support | |
| # | |
| # Based on: | |
| # http://sourceforge.net/p/mingw-w64/wiki2/Native%20Win64%20compiler/ | |
| # http://sourceforge.net/p/mingw-w64/code/HEAD/tree/stable/v3.x/mingw-w64-doc/howto-build/mingw-w64-howto-build.txt?format=raw | |
| # | |
| # Cross compiling notes: | |
| # - The minor version of gcc must match that of our cross compiler (4.8 in this case) | |
| # - Important parameters: http://gcc.gnu.org/onlinedocs/gccint/Configure-Terms.html | |
| # |
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
| df <- as.data.frame(read.dcf(url('https://cran.r-universe.dev/bin/linux/noble-x86_64/4.5/src/contrib/PACKAGES'))) | |
| unknown_platform <- df$NeedsCompilation == 'yes' & !grepl('linux', df$Built) | |
| df$Package[unknown_platform] |
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
| # Bioc packages with 'hard' dependency on data packages | |
| # Please consider making these a 'soft' dependency (aka Suggests) if data is only needed for examples/vignettes. | |
| software <- available.packages(repos = 'https://bioconductor.org/packages/devel/bioc/') | |
| annotation <- available.packages(repos = 'https://bioconductor.org/packages/release/data/annotation') | |
| experiment <- available.packages(repos = 'https://bioconductor.org/packages/release/data/experiment') | |
| datapkgs <- c(row.names(annotation), row.names(experiment)) | |
| deps <- tools::package_dependencies(db = software) | |
| datadeps <- sapply(deps, function(x){ | |
| intersect(x, datapkgs) | |
| }, simplify = FALSE) |
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
| //Compile: gcc test.c $(pkg-config --libs --cflags libgit2) | |
| #include <git2.h> | |
| #include <stdio.h> | |
| int main() { | |
| git_libgit2_init(); | |
| git_repository *repo = NULL; | |
| int error = git_clone(&repo, "https://github.com/jeroen/sys", "test", NULL); | |
| if (error < 0) { |
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
| # Minimal example of Shiny widget using 'magick' images | |
| ui <- fluidPage( | |
| titlePanel("Magick Shiny Demo"), | |
| sidebarLayout( | |
| sidebarPanel( | |
| fileInput("upload", "Upload new image", accept = c('image/png', 'image/jpeg')), | |
| textInput("size", "Size", value = "500x500"), |
NewerOlder