From 41a471ddb569b93f709b894f452b312a92982a6c Mon Sep 17 00:00:00 2001 From: mewu Date: Wed, 9 Oct 2024 15:40:51 -0700 Subject: [PATCH] add new env --- .devcontainer/devcontainer.json | 3 +- .devcontainer/postCreateCommand_r.sh | 12 + .devcontainer/postStartCommand.sh | 6 +- .github/workflows/publish.yml | 50 +- Dockerfile | 40 +- python/{ => samples/sir}/requirements.txt | 0 .../sir}/sir_model_simulation.ipynb | 0 r/{ => samples}/shinylive_demo/_quarto.yml | 0 .../shinylive_demo}/install_packages.R | 0 r/samples/shinylive_demo/shiny_demo.ipynb | 205 +++ .../shinylive_demo/simple_example.qmd | 0 r/samples/simple_plot/install_packages.R | 26 + r/{ => samples}/simple_plot/simple_plot.qmd | 0 r/shinylive_demo/renv.lock | 1463 ----------------- r/shinylive_demo/shinylive_demo.Rproj | 13 - r/simple_plot/renv.lock | 833 ---------- r/simple_plot/simple_plot.Rproj | 13 - run_quarto_publish.sh | 110 ++ 18 files changed, 392 insertions(+), 2382 deletions(-) create mode 100644 .devcontainer/postCreateCommand_r.sh rename python/{ => samples/sir}/requirements.txt (100%) rename python/{ => samples/sir}/sir_model_simulation.ipynb (100%) rename r/{ => samples}/shinylive_demo/_quarto.yml (100%) rename r/{ => samples/shinylive_demo}/install_packages.R (100%) create mode 100644 r/samples/shinylive_demo/shiny_demo.ipynb rename r/{ => samples}/shinylive_demo/simple_example.qmd (100%) create mode 100644 r/samples/simple_plot/install_packages.R rename r/{ => samples}/simple_plot/simple_plot.qmd (100%) delete mode 100644 r/shinylive_demo/renv.lock delete mode 100644 r/shinylive_demo/shinylive_demo.Rproj delete mode 100644 r/simple_plot/renv.lock delete mode 100644 r/simple_plot/simple_plot.Rproj create mode 100644 run_quarto_publish.sh diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 2e5d815..e949647 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -6,6 +6,7 @@ "version": "3.12", "installJupyterlab": true }, + "ghcr.io/devcontainers/features/anaconda:1": {}, "ghcr.io/rocker-org/devcontainer-features/quarto-cli:1": {} }, "customizations": { @@ -21,7 +22,7 @@ } } }, - "postCreateCommand": "", + "postCreateCommand": "bash ./.devcontainer/postCreateCommand_r.sh", "postStartCommand": "bash ./.devcontainer/postStartCommand.sh", "portsAttributes": { "8888": { diff --git a/.devcontainer/postCreateCommand_r.sh b/.devcontainer/postCreateCommand_r.sh new file mode 100644 index 0000000..ad94205 --- /dev/null +++ b/.devcontainer/postCreateCommand_r.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +# Install ZeroMQ +sudo apt-get update -y +sudo apt-get install libzmq3-dev -y + +# Setup bash to allow conda to run +conda init bash && conda install -y ipykernel + +# Allow JupyterLab and IRkernel ro run R workbook +R -e "install.packages('IRkernel')" +R -e "IRkernel::installspec()" diff --git a/.devcontainer/postStartCommand.sh b/.devcontainer/postStartCommand.sh index 4a95519..532713a 100644 --- a/.devcontainer/postStartCommand.sh +++ b/.devcontainer/postStartCommand.sh @@ -1,7 +1,7 @@ #!/bin/bash # change the default working directory for RStudio -echo "session-default-working-dir=${CODESPACE_VSCODE_FOLDER}" | sudo tee -a /etc/rstudio/rsession.conf +echo "session-default-working-dir=/workspaces/quarto_demo/" | sudo tee -a /etc/rstudio/rsession.conf # Start RStudio Server echo "Start R studeio Server" @@ -15,11 +15,11 @@ fi sleep 5 echo "Setup Jupyter-lab" # Start Jupyter Lab -jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' > jupyter_lab.log 2>&1 & +nohup jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' > jupyter_lab.log 2>&1 & sleep 5 if ! pgrep -x "jupyter-lab" > /dev/null; then echo "Jupyter Lab failed to start. Restarting..." - jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' > jupyter_lab.log 2>&1 & + nohup jupyter lab --ip=0.0.0.0 --port=8888 --no-browser --allow-root --NotebookApp.token='' > jupyter_lab.log 2>&1 & fi echo "Dev environment startup completed!" diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index cd43f48..9e0aa8b 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -28,54 +28,7 @@ jobs: - name: Run Quarto in Docker container run: | - docker run --rm -v ${{ github.workspace }}:/workspace -w /workspace mewu/data_access:latest bash -c " - - source /opt/venv/bin/activate - echo 'activated virtualenv.' - - chmod +x /workspace/r/install_quarto_extensions.expect - /workspace/r/install_quarto_extensions.expect - quarto list extensions - echo 'Check Quarto status:' - quarto check - echo 'Check R script path:' - which Rscript - - FOLDERS=(python r) - echo 'Folders to process: \${FOLDERS[@]}' - - for FOLDER in \"\${FOLDERS[@]}\"; do - echo \"Searching for .qmd and .ipynb files in /workspace/\$FOLDER...\" - find \"/workspace/\$FOLDER\" \( -name '*.qmd' -o -name '*.ipynb' \) | while read -r file; do - - echo \"Processing file: \$file\" - # Remove the /workspace prefix from the file path - relative_dir=\$(dirname \"\${file#'/workspace/'}\") - - # Install extension to the folder directly - pushd \$relative_dir - /workspace/r/install_quarto_extensions.expect - popd - - target_dir=\"/workspace/gallery/\$relative_dir\" - echo \"Creating target directory: \$target_dir\" - mkdir -p \"\$target_dir\" && echo \"Directory \$target_dir created.\" - - echo \"Attempting to render \$file with execution...\" - if quarto render \"\$file\" --to html --output-dir \"\$target_dir\"; then - echo \"Successfully rendered \$file with execution.\" - else - echo \"Failed to render \$file with execution. Rendering without execution...\" - if quarto render \"\$file\" --to html --no-execute --output-dir \"\$target_dir\"; then - echo \"Successfully rendered \$file without execution.\" - else - echo \"Rendering failed for \$file, even without execution.\" - fi - fi - - done - done" - + docker run --rm -v ${{ github.workspace }}:/workspace -w /workspace mewu/data_access:latest bash -c "run_quarto_publish.sh" - name: Generate Index HTML run: | @@ -101,6 +54,7 @@ jobs: git config --global user.email 'github-actions[bot]@users.noreply.github.com' - name: Deploy to GitHub Pages + if: github.ref == 'refs/heads/main' uses: peaceiris/actions-gh-pages@v4 with: github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/Dockerfile b/Dockerfile index bf1fe71..f0ebdee 100644 --- a/Dockerfile +++ b/Dockerfile @@ -25,6 +25,15 @@ RUN apt-get update && apt-get install -y \ libharfbuzz-dev \ libfribidi-dev \ libfreetype6-dev \ + libgl1-mesa-glx \ + libegl1-mesa \ + libxrandr2 \ + libxss1 \ + libxcursor1 \ + libxcomposite1 \ + libasound2 \ + libxi6 \ + libxtst6 \ gdebi-core \ software-properties-common \ ffmpeg \ @@ -56,24 +65,39 @@ RUN /opt/venv/bin/python -m ipykernel install --user --name=venv --display-name RUN wget https://github.com/quarto-dev/quarto-cli/releases/download/v1.5.57/quarto-1.5.57-linux-amd64.deb RUN dpkg -i quarto-1.5.57-linux-amd64.deb -# Expose ports for RStudio (8787) and Jupyter (8888) +# Install Anaconda +# Set environment variable for non-interactive Anaconda install +ENV PATH /opt/conda/bin:$PATH + +# Download and install Anaconda +RUN wget --quiet https://repo.anaconda.com/archive/Anaconda3-2023.09-0-Linux-x86_64.sh -O ~/anaconda.sh && \ + /bin/bash ~/anaconda.sh -b -p /opt/conda && \ + rm ~/anaconda.sh && \ + /opt/conda/bin/conda clean -i -t -p -y + +# Update conda to the latest version +RUN conda update -n base -c defaults conda + +# Set the default shell to bash and activate Conda environment +SHELL ["/bin/bash", "-c"] + +# Ensure conda is activated on startup +RUN echo "source /opt/conda/etc/profile.d/conda.sh" >> ~/.bashrc WORKDIR /app COPY r /app/r COPY python /app/python -# Install python packages in venv -RUN /opt/venv/bin/pip install -r python/requirements.txt - +# Expose ports for RStudio (8787) and Jupyter (8888) EXPOSE 8787 EXPOSE 8888 -# Install renv globally for all users +# Install essentials globally for all users RUN R -e "install.packages('renv', repos='https://cran.rstudio.com/')" - -# Install R packages -RUN Rscript /app/r/install_packages.R +RUN R -e "install.packages('knitr', repos='https://cran.rstudio.com/')" +RUN R -e "install.packages('rmarkdown', repos='https://cran.rstudio.com/')" +RUN R -e ".libPaths()" # Add /usr/local/bin to the PATH for all users ENV PATH="/usr/local/bin:$PATH" diff --git a/python/requirements.txt b/python/samples/sir/requirements.txt similarity index 100% rename from python/requirements.txt rename to python/samples/sir/requirements.txt diff --git a/python/sir_model_simulation.ipynb b/python/samples/sir/sir_model_simulation.ipynb similarity index 100% rename from python/sir_model_simulation.ipynb rename to python/samples/sir/sir_model_simulation.ipynb diff --git a/r/shinylive_demo/_quarto.yml b/r/samples/shinylive_demo/_quarto.yml similarity index 100% rename from r/shinylive_demo/_quarto.yml rename to r/samples/shinylive_demo/_quarto.yml diff --git a/r/install_packages.R b/r/samples/shinylive_demo/install_packages.R similarity index 100% rename from r/install_packages.R rename to r/samples/shinylive_demo/install_packages.R diff --git a/r/samples/shinylive_demo/shiny_demo.ipynb b/r/samples/shinylive_demo/shiny_demo.ipynb new file mode 100644 index 0000000..dc094ef --- /dev/null +++ b/r/samples/shinylive_demo/shiny_demo.ipynb @@ -0,0 +1,205 @@ +{ + "cells": [ + { + "cell_type": "code", + "execution_count": 7, + "id": "88b29033-79a1-40f1-a755-8f10e67f3442", + "metadata": {}, + "outputs": [ + { + "name": "stderr", + "output_type": "stream", + "text": [ + "Installing package into ‘/usr/local/lib/R/site-library’\n", + "(as ‘lib’ is unspecified)\n", + "\n", + "Installing package into ‘/usr/local/lib/R/site-library’\n", + "(as ‘lib’ is unspecified)\n", + "\n", + "Installing package into ‘/usr/local/lib/R/site-library’\n", + "(as ‘lib’ is unspecified)\n", + "\n", + "Installing package into ‘/usr/local/lib/R/site-library’\n", + "(as ‘lib’ is unspecified)\n", + "\n", + "Installing package into ‘/usr/local/lib/R/site-library’\n", + "(as ‘lib’ is unspecified)\n", + "\n", + "also installing the dependencies ‘colorspace’, ‘farver’, ‘labeling’, ‘munsell’, ‘RColorBrewer’, ‘viridisLite’, ‘gtable’, ‘isoband’, ‘scales’\n", + "\n", + "\n" + ] + } + ], + "source": [ + "install.packages(\"shinylive\")\n", + "install.packages(\"shiny\")\n", + "install.packages(\"shinyWidgets\")\n", + "install.packages(\"dplyr\")\n", + "install.packages(\"ggplot2\")" + ] + }, + { + "cell_type": "markdown", + "id": "e03329ba-510e-4f00-bd20-6ada312e5d0d", + "metadata": {}, + "source": [ + "---\n", + "title: \"Template for r-shinylive Quarto document (Covid Example)\"\n", + "format:\n", + " html:\n", + " resources: \n", + " - shinylive-sw.js\n", + "filters:\n", + " - shinylive\n", + "---" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "id": "09f6b537-b184-4ea6-b9b9-190f96207cdb", + "metadata": {}, + "outputs": [], + "source": [ + "options(timeout = 6000)\n", + "library(shiny)\n", + "library(dplyr)\n", + "library(ggplot2)\n", + "library(shinyWidgets)\n", + "\n", + "# Download real COVID data for Washington state counties from the New York Times GitHub repo\n", + "covid_url <- \"https://raw.githubusercontent.com/nytimes/covid-19-data/master/us-counties.csv\"\n", + "covid_data <- read.csv(covid_url)" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "id": "0a03f7b5-18cf-4df3-98b7-657cd171731e", + "metadata": {}, + "outputs": [ + { + "name": "stderr", + "output_type": "stream", + "text": [ + "\n", + "Listening on http://127.0.0.1:7477\n", + "\n" + ] + } + ], + "source": [ + "\n", + "# Filter for Washington state and prepare the data\n", + "washington_covid_data <- covid_data %>%\n", + " filter(state == \"Washington\") %>%\n", + " select(date, county, cases) %>%\n", + " mutate(year_month = format(as.Date(date), \"%Y%m\")) # Create year_month column\n", + "\n", + "# Create a vector of unique year_month values from the dataset\n", + "valid_year_months <- sort(unique(washington_covid_data$year_month))\n", + "valid_year_months_index <- seq_along(valid_year_months)\n", + "\n", + "# Define the UI\n", + "ui <- fluidPage(\n", + " titlePanel(\"COVID Case Counts by Month-Year in Washington Counties\"),\n", + " \n", + " # Use fluidRow to place the slider at the top, spanning the entire page width\n", + " fluidRow(\n", + " column(12, # 12 columns to span full width\n", + " sliderTextInput(\"selected_year_month\", \n", + " \"Select Year and Month:\", \n", + " choices = valid_year_months, # Use year-month values directly\n", + " selected = \"202001\", # Start with the first year-month\n", + " animate = animationOptions(interval = 1000, loop = FALSE))\n", + " )\n", + " ),\n", + " \n", + " # Main panel for the plot below the slider\n", + " fluidRow(\n", + " column(12, # This will also span the entire width\n", + " plotOutput(\"histogramPlot\")\n", + " )\n", + " )\n", + ")\n", + "\n", + "\n", + "# Define the server\n", + "server <- function(input, output) {\n", + " output$histogramPlot <- renderPlot({\n", + " filtered_data <- washington_covid_data %>%\n", + " filter(year_month == as.character(input$selected_year_month)) %>%\n", + " group_by(county) %>%\n", + " summarize(total_cases = max(cases, na.rm = TRUE)) # Get max case count for each county in the selected year_month\n", + " \n", + " ggplot(filtered_data, aes(x = county, y = total_cases)) +\n", + " geom_bar(stat = \"identity\", fill = \"steelblue\") +\n", + " labs(title = paste(\"COVID Cases in\", input$selected_year_month),\n", + " x = \"County\", \n", + " y = \"Total Case Count\") +\n", + " theme_minimal() +\n", + " theme(axis.text.x = element_text(angle = 45, hjust = 1))\n", + " })\n", + "}\n", + "\n", + "# Run the Shiny app\n", + "shinyApp(ui = ui, server = server)" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "id": "d050a599-2d6c-4338-9d6f-5ed08de7f98e", + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "'/workspaces/quarto_demo/.devcontainer'" + ], + "text/latex": [ + "'/workspaces/quarto\\_demo/.devcontainer'" + ], + "text/markdown": [ + "'/workspaces/quarto_demo/.devcontainer'" + ], + "text/plain": [ + "[1] \"/workspaces/quarto_demo/.devcontainer\"" + ] + }, + "metadata": {}, + "output_type": "display_data" + } + ], + "source": [ + "getwd()" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "id": "bf722ea2-9268-4a24-a275-4a3cf4c7c766", + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "R", + "language": "R", + "name": "ir" + }, + "language_info": { + "codemirror_mode": "r", + "file_extension": ".r", + "mimetype": "text/x-r-source", + "name": "R", + "pygments_lexer": "r", + "version": "4.4.1" + } + }, + "nbformat": 4, + "nbformat_minor": 5 +} diff --git a/r/shinylive_demo/simple_example.qmd b/r/samples/shinylive_demo/simple_example.qmd similarity index 100% rename from r/shinylive_demo/simple_example.qmd rename to r/samples/shinylive_demo/simple_example.qmd diff --git a/r/samples/simple_plot/install_packages.R b/r/samples/simple_plot/install_packages.R new file mode 100644 index 0000000..fb70d22 --- /dev/null +++ b/r/samples/simple_plot/install_packages.R @@ -0,0 +1,26 @@ +options(Ncpus = parallel::detectCores()) + +if (.Platform$OS.type == "unix") { + type <- "source" +}else{ + type <- "binary" +} + + +pkgnames <- c( +'devtools', 'DT', +'dplyr','ggplot2', 'plotly', 'tidyr', 'stringr', 'logr', 'tidyverse', +'knitr', 'rmarkdown', +"leaflet", "leaflet.extras" +) + +print(paste0("Install Packages from Cran : ", pkgnames)) +install.packages(pkgnames, + repos='http://cran.rstudio.com/', + type=type) + +# Make sure packages are available +if (length(pkgnames[which (!pkgnames %in% installed.packages()[,'Package'])]) >0 ){ + cat(paste0("Package did not install correctly:", c(pkgnames[which (!pkgnames %in% installed.packages()[,'Package'])]), "\n")) + stop("some packages are not available, please investigate...") +} \ No newline at end of file diff --git a/r/simple_plot/simple_plot.qmd b/r/samples/simple_plot/simple_plot.qmd similarity index 100% rename from r/simple_plot/simple_plot.qmd rename to r/samples/simple_plot/simple_plot.qmd diff --git a/r/shinylive_demo/renv.lock b/r/shinylive_demo/renv.lock deleted file mode 100644 index 9fb8fd8..0000000 --- a/r/shinylive_demo/renv.lock +++ /dev/null @@ -1,1463 +0,0 @@ -{ - "R": { - "Version": "4.4.0", - "Repositories": [ - { - "Name": "CRAN", - "URL": "https://packagemanager.posit.co/cran/latest" - } - ] - }, - "Packages": { - "KernSmooth": { - "Package": "KernSmooth", - "Version": "2.23-24", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "stats" - ], - "Hash": "9f33a1ee37bbe8919eb2ec4b9f2473a5" - }, - "MASS": { - "Package": "MASS", - "Version": "7.3-60.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "methods", - "stats", - "utils" - ], - "Hash": "2f342c46163b0b54d7b64d1f798e2c78" - }, - "Matrix": { - "Package": "Matrix", - "Version": "1.7-0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "lattice", - "methods", - "stats", - "utils" - ], - "Hash": "1920b2f11133b12350024297d8a4ff4a" - }, - "R6": { - "Package": "R6", - "Version": "2.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "470851b6d5d0ac559e9d01bb352b4021" - }, - "RColorBrewer": { - "Package": "RColorBrewer", - "Version": "1.1-3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "45f0398006e83a5b10b72a90663d8d8c" - }, - "Rcpp": { - "Package": "Rcpp", - "Version": "1.0.13", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "methods", - "utils" - ], - "Hash": "f27411eb6d9c3dada5edd444b8416675" - }, - "archive": { - "Package": "archive", - "Version": "1.1.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "rlang", - "tibble" - ], - "Hash": "d26b62e131d4a8b65aba4e9554a4bf74" - }, - "askpass": { - "Package": "askpass", - "Version": "1.2.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "sys" - ], - "Hash": "cad6cf7f1d5f6e906700b9d3e718c796" - }, - "base64enc": { - "Package": "base64enc", - "Version": "0.1-3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "543776ae6848fde2f48ff3816d0628bc" - }, - "boot": { - "Package": "boot", - "Version": "1.3-30", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "graphics", - "stats" - ], - "Hash": "96abeed416a286d4a0f52e550b612343" - }, - "brio": { - "Package": "brio", - "Version": "1.1.5", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "c1ee497a6d999947c2c224ae46799b1a" - }, - "bslib": { - "Package": "bslib", - "Version": "0.8.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "base64enc", - "cachem", - "fastmap", - "grDevices", - "htmltools", - "jquerylib", - "jsonlite", - "lifecycle", - "memoise", - "mime", - "rlang", - "sass" - ], - "Hash": "b299c6741ca9746fb227debcb0f9fb6c" - }, - "cachem": { - "Package": "cachem", - "Version": "1.1.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "fastmap", - "rlang" - ], - "Hash": "cd9a672193789068eb5a2aad65a0dedf" - }, - "callr": { - "Package": "callr", - "Version": "3.7.6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "processx", - "utils" - ], - "Hash": "d7e13f49c19103ece9e58ad2d83a7354" - }, - "class": { - "Package": "class", - "Version": "7.3-22", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "MASS", - "R", - "stats", - "utils" - ], - "Hash": "f91f6b29f38b8c280f2b9477787d4bb2" - }, - "cli": { - "Package": "cli", - "Version": "3.6.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "b21916dd77a27642b447374a5d30ecf3" - }, - "cluster": { - "Package": "cluster", - "Version": "2.1.6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "stats", - "utils" - ], - "Hash": "0aaa05204035dc43ea0004b9c76611dd" - }, - "codetools": { - "Package": "codetools", - "Version": "0.2-20", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "61e097f35917d342622f21cdc79c256e" - }, - "colorspace": { - "Package": "colorspace", - "Version": "2.1-1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "methods", - "stats" - ], - "Hash": "d954cb1c57e8d8b756165d7ba18aa55a" - }, - "commonmark": { - "Package": "commonmark", - "Version": "1.9.1", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "5d8225445acb167abf7797de48b2ee3c" - }, - "crayon": { - "Package": "crayon", - "Version": "1.5.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "grDevices", - "methods", - "utils" - ], - "Hash": "859d96e65ef198fd43e82b9628d593ef" - }, - "crosstalk": { - "Package": "crosstalk", - "Version": "1.2.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R6", - "htmltools", - "jsonlite", - "lazyeval" - ], - "Hash": "ab12c7b080a57475248a30f4db6298c0" - }, - "curl": { - "Package": "curl", - "Version": "5.2.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "d91263322a58af798f6cf3b13fd56dde" - }, - "desc": { - "Package": "desc", - "Version": "1.4.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "cli", - "utils" - ], - "Hash": "99b79fcbd6c4d1ce087f5c5c758b384f" - }, - "digest": { - "Package": "digest", - "Version": "0.6.37", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "33698c4b3127fc9f506654607fb73676" - }, - "dplyr": { - "Package": "dplyr", - "Version": "1.1.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "cli", - "generics", - "glue", - "lifecycle", - "magrittr", - "methods", - "pillar", - "rlang", - "tibble", - "tidyselect", - "utils", - "vctrs" - ], - "Hash": "fedd9d00c2944ff00a0e2696ccf048ec" - }, - "evaluate": { - "Package": "evaluate", - "Version": "1.0.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "6b567375113ceb7d9f800de4dd42218e" - }, - "fansi": { - "Package": "fansi", - "Version": "1.0.6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "utils" - ], - "Hash": "962174cf2aeb5b9eea581522286a911f" - }, - "farver": { - "Package": "farver", - "Version": "2.1.2", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "680887028577f3fa2a81e410ed0d6e42" - }, - "fastmap": { - "Package": "fastmap", - "Version": "1.2.0", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "aa5e1cd11c2d15497494c5292d7ffcc8" - }, - "filelock": { - "Package": "filelock", - "Version": "1.0.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "192053c276525c8495ccfd523aa8f2d1" - }, - "fontawesome": { - "Package": "fontawesome", - "Version": "0.5.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools", - "rlang" - ], - "Hash": "c2efdd5f0bcd1ea861c2d4e2a883a67d" - }, - "foreign": { - "Package": "foreign", - "Version": "0.8-86", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods", - "stats", - "utils" - ], - "Hash": "550170303dbb19d07b2bcc288068e7dc" - }, - "fs": { - "Package": "fs", - "Version": "1.6.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods" - ], - "Hash": "15aeb8c27f5ea5161f9f6a641fafd93a" - }, - "generics": { - "Package": "generics", - "Version": "0.1.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods" - ], - "Hash": "15e9634c0fcd294799e9b2e929ed1b86" - }, - "ggplot2": { - "Package": "ggplot2", - "Version": "3.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "MASS", - "R", - "cli", - "glue", - "grDevices", - "grid", - "gtable", - "isoband", - "lifecycle", - "mgcv", - "rlang", - "scales", - "stats", - "tibble", - "vctrs", - "withr" - ], - "Hash": "44c6a2f8202d5b7e878ea274b1092426" - }, - "gh": { - "Package": "gh", - "Version": "1.4.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "gitcreds", - "glue", - "httr2", - "ini", - "jsonlite", - "lifecycle", - "rlang" - ], - "Hash": "fbbbc48eba7a6626a08bb365e44b563b" - }, - "gitcreds": { - "Package": "gitcreds", - "Version": "0.1.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "ab08ac61f3e1be454ae21911eb8bc2fe" - }, - "glue": { - "Package": "glue", - "Version": "1.7.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods" - ], - "Hash": "e0b3a53876554bd45879e596cdb10a52" - }, - "gtable": { - "Package": "gtable", - "Version": "0.3.5", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "grid", - "lifecycle", - "rlang" - ], - "Hash": "e18861963cbc65a27736e02b3cd3c4a0" - }, - "highr": { - "Package": "highr", - "Version": "0.11", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "xfun" - ], - "Hash": "d65ba49117ca223614f71b60d85b8ab7" - }, - "hms": { - "Package": "hms", - "Version": "1.1.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "lifecycle", - "methods", - "pkgconfig", - "rlang", - "vctrs" - ], - "Hash": "b59377caa7ed00fa41808342002138f9" - }, - "htmltools": { - "Package": "htmltools", - "Version": "0.5.8.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "base64enc", - "digest", - "fastmap", - "grDevices", - "rlang", - "utils" - ], - "Hash": "81d371a9cc60640e74e4ab6ac46dcedc" - }, - "htmlwidgets": { - "Package": "htmlwidgets", - "Version": "1.6.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "grDevices", - "htmltools", - "jsonlite", - "knitr", - "rmarkdown", - "yaml" - ], - "Hash": "04291cc45198225444a397606810ac37" - }, - "httpuv": { - "Package": "httpuv", - "Version": "1.6.15", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "Rcpp", - "later", - "promises", - "utils" - ], - "Hash": "d55aa087c47a63ead0f6fc10f8fa1ee0" - }, - "httr2": { - "Package": "httr2", - "Version": "1.0.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "cli", - "curl", - "glue", - "lifecycle", - "magrittr", - "openssl", - "rappdirs", - "rlang", - "vctrs", - "withr" - ], - "Hash": "836e9564fbeca3bb390bb429a53cd401" - }, - "ini": { - "Package": "ini", - "Version": "0.3.1", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "6154ec2223172bce8162d4153cda21f7" - }, - "isoband": { - "Package": "isoband", - "Version": "0.2.7", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "grid", - "utils" - ], - "Hash": "0080607b4a1a7b28979aecef976d8bc2" - }, - "jquerylib": { - "Package": "jquerylib", - "Version": "0.1.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "htmltools" - ], - "Hash": "5aab57a3bd297eee1c1d862735972182" - }, - "jsonlite": { - "Package": "jsonlite", - "Version": "1.8.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "methods" - ], - "Hash": "4e993b65c2c3ffbffce7bb3e2c6f832b" - }, - "knitr": { - "Package": "knitr", - "Version": "1.48", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "evaluate", - "highr", - "methods", - "tools", - "xfun", - "yaml" - ], - "Hash": "acf380f300c721da9fde7df115a5f86f" - }, - "labeling": { - "Package": "labeling", - "Version": "0.4.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "graphics", - "stats" - ], - "Hash": "b64ec208ac5bc1852b285f665d6368b3" - }, - "later": { - "Package": "later", - "Version": "1.3.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "Rcpp", - "rlang" - ], - "Hash": "a3e051d405326b8b0012377434c62b37" - }, - "lattice": { - "Package": "lattice", - "Version": "0.22-6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "stats", - "utils" - ], - "Hash": "cc5ac1ba4c238c7ca9fa6a87ca11a7e2" - }, - "lazyeval": { - "Package": "lazyeval", - "Version": "0.2.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "d908914ae53b04d4c0c0fd72ecc35370" - }, - "leaflet": { - "Package": "leaflet", - "Version": "2.2.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "RColorBrewer", - "crosstalk", - "htmltools", - "htmlwidgets", - "jquerylib", - "leaflet.providers", - "magrittr", - "methods", - "png", - "raster", - "scales", - "sp", - "stats", - "viridisLite", - "xfun" - ], - "Hash": "ca012d4a706e21ce217ba15f22d402b2" - }, - "leaflet.extras": { - "Package": "leaflet.extras", - "Version": "2.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools", - "htmlwidgets", - "leaflet", - "magrittr", - "stringr" - ], - "Hash": "1626fb22ec9e788f66c1d08fd863da4c" - }, - "leaflet.providers": { - "Package": "leaflet.providers", - "Version": "2.0.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools" - ], - "Hash": "c0b81ad9d5d932772f7a457ac398cf36" - }, - "lifecycle": { - "Package": "lifecycle", - "Version": "1.0.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "rlang" - ], - "Hash": "b8552d117e1b808b09a832f589b79035" - }, - "lpSolve": { - "Package": "lpSolve", - "Version": "5.6.21", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "730a90bdc519fb0caff03df11218ddd8" - }, - "magrittr": { - "Package": "magrittr", - "Version": "2.0.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "7ce2733a9826b3aeb1775d56fd305472" - }, - "memoise": { - "Package": "memoise", - "Version": "2.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "cachem", - "rlang" - ], - "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c" - }, - "mgcv": { - "Package": "mgcv", - "Version": "1.9-1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "Matrix", - "R", - "graphics", - "methods", - "nlme", - "splines", - "stats", - "utils" - ], - "Hash": "110ee9d83b496279960e162ac97764ce" - }, - "mime": { - "Package": "mime", - "Version": "0.12", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "tools" - ], - "Hash": "18e9c28c1d3ca1560ce30658b22ce104" - }, - "munsell": { - "Package": "munsell", - "Version": "0.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "colorspace", - "methods" - ], - "Hash": "4fd8900853b746af55b81fda99da7695" - }, - "nlme": { - "Package": "nlme", - "Version": "3.1-164", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "graphics", - "lattice", - "stats", - "utils" - ], - "Hash": "a623a2239e642806158bc4dc3f51565d" - }, - "nnet": { - "Package": "nnet", - "Version": "7.3-19", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "stats", - "utils" - ], - "Hash": "2c797b46eea7fb58ede195bc0b1f1138" - }, - "openssl": { - "Package": "openssl", - "Version": "2.2.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "askpass" - ], - "Hash": "d413e0fef796c9401a4419485f709ca1" - }, - "pillar": { - "Package": "pillar", - "Version": "1.9.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "cli", - "fansi", - "glue", - "lifecycle", - "rlang", - "utf8", - "utils", - "vctrs" - ], - "Hash": "15da5a8412f317beeee6175fbc76f4bb" - }, - "pkgbuild": { - "Package": "pkgbuild", - "Version": "1.4.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "callr", - "cli", - "desc", - "processx" - ], - "Hash": "a29e8e134a460a01e0ca67a4763c595b" - }, - "pkgcache": { - "Package": "pkgcache", - "Version": "2.2.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "callr", - "cli", - "curl", - "filelock", - "jsonlite", - "processx", - "tools", - "utils" - ], - "Hash": "502554da4ec4d917b737e6b0fe14dd11" - }, - "pkgconfig": { - "Package": "pkgconfig", - "Version": "2.0.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "utils" - ], - "Hash": "01f28d4278f15c76cddbea05899c5d6f" - }, - "pkgdepends": { - "Package": "pkgdepends", - "Version": "0.8.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "callr", - "cli", - "curl", - "desc", - "filelock", - "jsonlite", - "lpSolve", - "pkgbuild", - "pkgcache", - "processx", - "ps", - "stats", - "utils", - "zip" - ], - "Hash": "eb7e3e965327555a527196d26d0643e4" - }, - "png": { - "Package": "png", - "Version": "0.1-8", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "bd54ba8a0a5faded999a7aab6e46b374" - }, - "prettyunits": { - "Package": "prettyunits", - "Version": "1.2.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "6b01fc98b1e86c4f705ce9dcfd2f57c7" - }, - "processx": { - "Package": "processx", - "Version": "3.8.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "ps", - "utils" - ], - "Hash": "0c90a7d71988856bad2a2a45dd871bb9" - }, - "progress": { - "Package": "progress", - "Version": "1.2.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "crayon", - "hms", - "prettyunits" - ], - "Hash": "f4625e061cb2865f111b47ff163a5ca6" - }, - "promises": { - "Package": "promises", - "Version": "1.3.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R6", - "Rcpp", - "fastmap", - "later", - "magrittr", - "rlang", - "stats" - ], - "Hash": "434cd5388a3979e74be5c219bcd6e77d" - }, - "ps": { - "Package": "ps", - "Version": "1.8.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "4b9c8485b0c7eecdf0a9ba5132a45576" - }, - "rappdirs": { - "Package": "rappdirs", - "Version": "0.3.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "5e3c5dc0b071b21fa128676560dbe94d" - }, - "raster": { - "Package": "raster", - "Version": "3.6-26", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "Rcpp", - "methods", - "sp", - "terra" - ], - "Hash": "7d6eda494f34a644420ac1bfd2a8023a" - }, - "renv": { - "Package": "renv", - "Version": "1.0.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "utils" - ], - "Hash": "ef233f0e9064fc88c898b340c9add5c2" - }, - "rlang": { - "Package": "rlang", - "Version": "1.1.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "3eec01f8b1dee337674b2e34ab1f9bc1" - }, - "rmarkdown": { - "Package": "rmarkdown", - "Version": "2.28", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "bslib", - "evaluate", - "fontawesome", - "htmltools", - "jquerylib", - "jsonlite", - "knitr", - "methods", - "tinytex", - "tools", - "utils", - "xfun", - "yaml" - ], - "Hash": "062470668513dcda416927085ee9bdc7" - }, - "rpart": { - "Package": "rpart", - "Version": "4.1.23", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "stats" - ], - "Hash": "b3d390424f41d04174cccf84d49676c2" - }, - "sass": { - "Package": "sass", - "Version": "0.4.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R6", - "fs", - "htmltools", - "rappdirs", - "rlang" - ], - "Hash": "d53dbfddf695303ea4ad66f86e99b95d" - }, - "scales": { - "Package": "scales", - "Version": "1.3.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "RColorBrewer", - "cli", - "farver", - "glue", - "labeling", - "lifecycle", - "munsell", - "rlang", - "viridisLite" - ], - "Hash": "c19df082ba346b0ffa6f833e92de34d1" - }, - "shiny": { - "Package": "shiny", - "Version": "1.9.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "bslib", - "cachem", - "commonmark", - "crayon", - "fastmap", - "fontawesome", - "glue", - "grDevices", - "htmltools", - "httpuv", - "jsonlite", - "later", - "lifecycle", - "methods", - "mime", - "promises", - "rlang", - "sourcetools", - "tools", - "utils", - "withr", - "xtable" - ], - "Hash": "6a293995a66e12c48d13aa1f957d09c7" - }, - "shinyWidgets": { - "Package": "shinyWidgets", - "Version": "0.8.7", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "bslib", - "grDevices", - "htmltools", - "jsonlite", - "rlang", - "sass", - "shiny" - ], - "Hash": "fd8239886f70daa85c36596214958451" - }, - "shinylive": { - "Package": "shinylive", - "Version": "0.2.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "archive", - "brio", - "cli", - "fs", - "gh", - "glue", - "httr2", - "jsonlite", - "pkgdepends", - "progress", - "rappdirs", - "renv", - "rlang", - "tools", - "whisker", - "withr" - ], - "Hash": "224c8c0502bb0ead1fd1b4b32ea04a90" - }, - "sourcetools": { - "Package": "sourcetools", - "Version": "0.1.7-1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "5f5a7629f956619d519205ec475fe647" - }, - "sp": { - "Package": "sp", - "Version": "2.1-4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "lattice", - "methods", - "stats", - "utils" - ], - "Hash": "75940133cca2e339afce15a586f85b11" - }, - "spatial": { - "Package": "spatial", - "Version": "7.3-17", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "graphics", - "stats", - "utils" - ], - "Hash": "1229a01b4ec059e9f2396724f2ec9010" - }, - "stringi": { - "Package": "stringi", - "Version": "1.8.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "stats", - "tools", - "utils" - ], - "Hash": "39e1144fd75428983dc3f63aa53dfa91" - }, - "stringr": { - "Package": "stringr", - "Version": "1.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "lifecycle", - "magrittr", - "rlang", - "stringi", - "vctrs" - ], - "Hash": "960e2ae9e09656611e0b8214ad543207" - }, - "survival": { - "Package": "survival", - "Version": "3.6-4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "Matrix", - "R", - "graphics", - "methods", - "splines", - "stats", - "utils" - ], - "Hash": "e6e3071f471513e4b85f98ca041303c7" - }, - "sys": { - "Package": "sys", - "Version": "3.4.2", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "3a1be13d68d47a8cd0bfd74739ca1555" - }, - "terra": { - "Package": "terra", - "Version": "1.7-78", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "Rcpp", - "methods" - ], - "Hash": "8f020def0792119cb98bd8f696dab22d" - }, - "tibble": { - "Package": "tibble", - "Version": "3.2.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "fansi", - "lifecycle", - "magrittr", - "methods", - "pillar", - "pkgconfig", - "rlang", - "utils", - "vctrs" - ], - "Hash": "a84e2cc86d07289b3b6f5069df7a004c" - }, - "tidyselect": { - "Package": "tidyselect", - "Version": "1.2.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "lifecycle", - "rlang", - "vctrs", - "withr" - ], - "Hash": "829f27b9c4919c16b593794a6344d6c0" - }, - "tinytex": { - "Package": "tinytex", - "Version": "0.53", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "xfun" - ], - "Hash": "9db859e8aabbb474293dde3097839420" - }, - "utf8": { - "Package": "utf8", - "Version": "1.2.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "62b65c52671e6665f803ff02954446e9" - }, - "vctrs": { - "Package": "vctrs", - "Version": "0.6.5", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "lifecycle", - "rlang" - ], - "Hash": "c03fa420630029418f7e6da3667aac4a" - }, - "viridisLite": { - "Package": "viridisLite", - "Version": "0.4.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "c826c7c4241b6fc89ff55aaea3fa7491" - }, - "whisker": { - "Package": "whisker", - "Version": "0.4.1", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "c6abfa47a46d281a7d5159d0a8891e88" - }, - "withr": { - "Package": "withr", - "Version": "3.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics" - ], - "Hash": "07909200e8bbe90426fbfeb73e1e27aa" - }, - "xfun": { - "Package": "xfun", - "Version": "0.47", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "stats", - "tools" - ], - "Hash": "36ab21660e2d095fef0d83f689e0477c" - }, - "xtable": { - "Package": "xtable", - "Version": "1.8-4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "stats", - "utils" - ], - "Hash": "b8acdf8af494d9ec19ccb2481a9b11c2" - }, - "yaml": { - "Package": "yaml", - "Version": "2.3.10", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "51dab85c6c98e50a18d7551e9d49f76c" - }, - "zip": { - "Package": "zip", - "Version": "2.3.1", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "fcc4bd8e6da2d2011eb64a5e5cc685ab" - } - } -} diff --git a/r/shinylive_demo/shinylive_demo.Rproj b/r/shinylive_demo/shinylive_demo.Rproj deleted file mode 100644 index 8e3c2eb..0000000 --- a/r/shinylive_demo/shinylive_demo.Rproj +++ /dev/null @@ -1,13 +0,0 @@ -Version: 1.0 - -RestoreWorkspace: Default -SaveWorkspace: Default -AlwaysSaveHistory: Default - -EnableCodeIndexing: Yes -UseSpacesForTab: Yes -NumSpacesForTab: 2 -Encoding: UTF-8 - -RnwWeave: Sweave -LaTeX: pdfLaTeX diff --git a/r/simple_plot/renv.lock b/r/simple_plot/renv.lock deleted file mode 100644 index be84633..0000000 --- a/r/simple_plot/renv.lock +++ /dev/null @@ -1,833 +0,0 @@ -{ - "R": { - "Version": "4.4.0", - "Repositories": [ - { - "Name": "CRAN", - "URL": "https://packagemanager.posit.co/cran/latest" - } - ] - }, - "Packages": { - "MASS": { - "Package": "MASS", - "Version": "7.3-60.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "methods", - "stats", - "utils" - ], - "Hash": "2f342c46163b0b54d7b64d1f798e2c78" - }, - "Matrix": { - "Package": "Matrix", - "Version": "1.7-0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "lattice", - "methods", - "stats", - "utils" - ], - "Hash": "1920b2f11133b12350024297d8a4ff4a" - }, - "R6": { - "Package": "R6", - "Version": "2.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "470851b6d5d0ac559e9d01bb352b4021" - }, - "RColorBrewer": { - "Package": "RColorBrewer", - "Version": "1.1-3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "45f0398006e83a5b10b72a90663d8d8c" - }, - "Rcpp": { - "Package": "Rcpp", - "Version": "1.0.13", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "methods", - "utils" - ], - "Hash": "f27411eb6d9c3dada5edd444b8416675" - }, - "base64enc": { - "Package": "base64enc", - "Version": "0.1-3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "543776ae6848fde2f48ff3816d0628bc" - }, - "bslib": { - "Package": "bslib", - "Version": "0.8.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "base64enc", - "cachem", - "fastmap", - "grDevices", - "htmltools", - "jquerylib", - "jsonlite", - "lifecycle", - "memoise", - "mime", - "rlang", - "sass" - ], - "Hash": "b299c6741ca9746fb227debcb0f9fb6c" - }, - "cachem": { - "Package": "cachem", - "Version": "1.1.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "fastmap", - "rlang" - ], - "Hash": "cd9a672193789068eb5a2aad65a0dedf" - }, - "cli": { - "Package": "cli", - "Version": "3.6.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "b21916dd77a27642b447374a5d30ecf3" - }, - "colorspace": { - "Package": "colorspace", - "Version": "2.1-1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "methods", - "stats" - ], - "Hash": "d954cb1c57e8d8b756165d7ba18aa55a" - }, - "crosstalk": { - "Package": "crosstalk", - "Version": "1.2.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R6", - "htmltools", - "jsonlite", - "lazyeval" - ], - "Hash": "ab12c7b080a57475248a30f4db6298c0" - }, - "digest": { - "Package": "digest", - "Version": "0.6.37", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "33698c4b3127fc9f506654607fb73676" - }, - "evaluate": { - "Package": "evaluate", - "Version": "1.0.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "6b567375113ceb7d9f800de4dd42218e" - }, - "fansi": { - "Package": "fansi", - "Version": "1.0.6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "utils" - ], - "Hash": "962174cf2aeb5b9eea581522286a911f" - }, - "farver": { - "Package": "farver", - "Version": "2.1.2", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "680887028577f3fa2a81e410ed0d6e42" - }, - "fastmap": { - "Package": "fastmap", - "Version": "1.2.0", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "aa5e1cd11c2d15497494c5292d7ffcc8" - }, - "fontawesome": { - "Package": "fontawesome", - "Version": "0.5.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools", - "rlang" - ], - "Hash": "c2efdd5f0bcd1ea861c2d4e2a883a67d" - }, - "fs": { - "Package": "fs", - "Version": "1.6.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods" - ], - "Hash": "15aeb8c27f5ea5161f9f6a641fafd93a" - }, - "ggplot2": { - "Package": "ggplot2", - "Version": "3.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "MASS", - "R", - "cli", - "glue", - "grDevices", - "grid", - "gtable", - "isoband", - "lifecycle", - "mgcv", - "rlang", - "scales", - "stats", - "tibble", - "vctrs", - "withr" - ], - "Hash": "44c6a2f8202d5b7e878ea274b1092426" - }, - "glue": { - "Package": "glue", - "Version": "1.7.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "methods" - ], - "Hash": "e0b3a53876554bd45879e596cdb10a52" - }, - "gtable": { - "Package": "gtable", - "Version": "0.3.5", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "grid", - "lifecycle", - "rlang" - ], - "Hash": "e18861963cbc65a27736e02b3cd3c4a0" - }, - "highr": { - "Package": "highr", - "Version": "0.11", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "xfun" - ], - "Hash": "d65ba49117ca223614f71b60d85b8ab7" - }, - "htmltools": { - "Package": "htmltools", - "Version": "0.5.8.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "base64enc", - "digest", - "fastmap", - "grDevices", - "rlang", - "utils" - ], - "Hash": "81d371a9cc60640e74e4ab6ac46dcedc" - }, - "htmlwidgets": { - "Package": "htmlwidgets", - "Version": "1.6.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "grDevices", - "htmltools", - "jsonlite", - "knitr", - "rmarkdown", - "yaml" - ], - "Hash": "04291cc45198225444a397606810ac37" - }, - "isoband": { - "Package": "isoband", - "Version": "0.2.7", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "grid", - "utils" - ], - "Hash": "0080607b4a1a7b28979aecef976d8bc2" - }, - "jquerylib": { - "Package": "jquerylib", - "Version": "0.1.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "htmltools" - ], - "Hash": "5aab57a3bd297eee1c1d862735972182" - }, - "jsonlite": { - "Package": "jsonlite", - "Version": "1.8.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "methods" - ], - "Hash": "4e993b65c2c3ffbffce7bb3e2c6f832b" - }, - "knitr": { - "Package": "knitr", - "Version": "1.48", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "evaluate", - "highr", - "methods", - "tools", - "xfun", - "yaml" - ], - "Hash": "acf380f300c721da9fde7df115a5f86f" - }, - "labeling": { - "Package": "labeling", - "Version": "0.4.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "graphics", - "stats" - ], - "Hash": "b64ec208ac5bc1852b285f665d6368b3" - }, - "lattice": { - "Package": "lattice", - "Version": "0.22-6", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "stats", - "utils" - ], - "Hash": "cc5ac1ba4c238c7ca9fa6a87ca11a7e2" - }, - "lazyeval": { - "Package": "lazyeval", - "Version": "0.2.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "d908914ae53b04d4c0c0fd72ecc35370" - }, - "leaflet": { - "Package": "leaflet", - "Version": "2.2.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "RColorBrewer", - "crosstalk", - "htmltools", - "htmlwidgets", - "jquerylib", - "leaflet.providers", - "magrittr", - "methods", - "png", - "raster", - "scales", - "sp", - "stats", - "viridisLite", - "xfun" - ], - "Hash": "ca012d4a706e21ce217ba15f22d402b2" - }, - "leaflet.extras": { - "Package": "leaflet.extras", - "Version": "2.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools", - "htmlwidgets", - "leaflet", - "magrittr", - "stringr" - ], - "Hash": "1626fb22ec9e788f66c1d08fd863da4c" - }, - "leaflet.providers": { - "Package": "leaflet.providers", - "Version": "2.0.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "htmltools" - ], - "Hash": "c0b81ad9d5d932772f7a457ac398cf36" - }, - "lifecycle": { - "Package": "lifecycle", - "Version": "1.0.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "rlang" - ], - "Hash": "b8552d117e1b808b09a832f589b79035" - }, - "magrittr": { - "Package": "magrittr", - "Version": "2.0.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "7ce2733a9826b3aeb1775d56fd305472" - }, - "memoise": { - "Package": "memoise", - "Version": "2.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "cachem", - "rlang" - ], - "Hash": "e2817ccf4a065c5d9d7f2cfbe7c1d78c" - }, - "mgcv": { - "Package": "mgcv", - "Version": "1.9-1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "Matrix", - "R", - "graphics", - "methods", - "nlme", - "splines", - "stats", - "utils" - ], - "Hash": "110ee9d83b496279960e162ac97764ce" - }, - "mime": { - "Package": "mime", - "Version": "0.12", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "tools" - ], - "Hash": "18e9c28c1d3ca1560ce30658b22ce104" - }, - "munsell": { - "Package": "munsell", - "Version": "0.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "colorspace", - "methods" - ], - "Hash": "4fd8900853b746af55b81fda99da7695" - }, - "nlme": { - "Package": "nlme", - "Version": "3.1-164", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "graphics", - "lattice", - "stats", - "utils" - ], - "Hash": "a623a2239e642806158bc4dc3f51565d" - }, - "pillar": { - "Package": "pillar", - "Version": "1.9.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "cli", - "fansi", - "glue", - "lifecycle", - "rlang", - "utf8", - "utils", - "vctrs" - ], - "Hash": "15da5a8412f317beeee6175fbc76f4bb" - }, - "pkgconfig": { - "Package": "pkgconfig", - "Version": "2.0.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "utils" - ], - "Hash": "01f28d4278f15c76cddbea05899c5d6f" - }, - "png": { - "Package": "png", - "Version": "0.1-8", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "bd54ba8a0a5faded999a7aab6e46b374" - }, - "rappdirs": { - "Package": "rappdirs", - "Version": "0.3.3", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "5e3c5dc0b071b21fa128676560dbe94d" - }, - "raster": { - "Package": "raster", - "Version": "3.6-26", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "Rcpp", - "methods", - "sp", - "terra" - ], - "Hash": "7d6eda494f34a644420ac1bfd2a8023a" - }, - "renv": { - "Package": "renv", - "Version": "1.0.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "utils" - ], - "Hash": "ef233f0e9064fc88c898b340c9add5c2" - }, - "rlang": { - "Package": "rlang", - "Version": "1.1.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "utils" - ], - "Hash": "3eec01f8b1dee337674b2e34ab1f9bc1" - }, - "rmarkdown": { - "Package": "rmarkdown", - "Version": "2.28", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "bslib", - "evaluate", - "fontawesome", - "htmltools", - "jquerylib", - "jsonlite", - "knitr", - "methods", - "tinytex", - "tools", - "utils", - "xfun", - "yaml" - ], - "Hash": "062470668513dcda416927085ee9bdc7" - }, - "sass": { - "Package": "sass", - "Version": "0.4.9", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R6", - "fs", - "htmltools", - "rappdirs", - "rlang" - ], - "Hash": "d53dbfddf695303ea4ad66f86e99b95d" - }, - "scales": { - "Package": "scales", - "Version": "1.3.0", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "R6", - "RColorBrewer", - "cli", - "farver", - "glue", - "labeling", - "lifecycle", - "munsell", - "rlang", - "viridisLite" - ], - "Hash": "c19df082ba346b0ffa6f833e92de34d1" - }, - "sp": { - "Package": "sp", - "Version": "2.1-4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics", - "grid", - "lattice", - "methods", - "stats", - "utils" - ], - "Hash": "75940133cca2e339afce15a586f85b11" - }, - "stringi": { - "Package": "stringi", - "Version": "1.8.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "stats", - "tools", - "utils" - ], - "Hash": "39e1144fd75428983dc3f63aa53dfa91" - }, - "stringr": { - "Package": "stringr", - "Version": "1.5.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "lifecycle", - "magrittr", - "rlang", - "stringi", - "vctrs" - ], - "Hash": "960e2ae9e09656611e0b8214ad543207" - }, - "terra": { - "Package": "terra", - "Version": "1.7-78", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "Rcpp", - "methods" - ], - "Hash": "8f020def0792119cb98bd8f696dab22d" - }, - "tibble": { - "Package": "tibble", - "Version": "3.2.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "fansi", - "lifecycle", - "magrittr", - "methods", - "pillar", - "pkgconfig", - "rlang", - "utils", - "vctrs" - ], - "Hash": "a84e2cc86d07289b3b6f5069df7a004c" - }, - "tinytex": { - "Package": "tinytex", - "Version": "0.53", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "xfun" - ], - "Hash": "9db859e8aabbb474293dde3097839420" - }, - "utf8": { - "Package": "utf8", - "Version": "1.2.4", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "62b65c52671e6665f803ff02954446e9" - }, - "vctrs": { - "Package": "vctrs", - "Version": "0.6.5", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "cli", - "glue", - "lifecycle", - "rlang" - ], - "Hash": "c03fa420630029418f7e6da3667aac4a" - }, - "viridisLite": { - "Package": "viridisLite", - "Version": "0.4.2", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R" - ], - "Hash": "c826c7c4241b6fc89ff55aaea3fa7491" - }, - "withr": { - "Package": "withr", - "Version": "3.0.1", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "graphics" - ], - "Hash": "07909200e8bbe90426fbfeb73e1e27aa" - }, - "xfun": { - "Package": "xfun", - "Version": "0.47", - "Source": "Repository", - "Repository": "CRAN", - "Requirements": [ - "R", - "grDevices", - "stats", - "tools" - ], - "Hash": "36ab21660e2d095fef0d83f689e0477c" - }, - "yaml": { - "Package": "yaml", - "Version": "2.3.10", - "Source": "Repository", - "Repository": "CRAN", - "Hash": "51dab85c6c98e50a18d7551e9d49f76c" - } - } -} diff --git a/r/simple_plot/simple_plot.Rproj b/r/simple_plot/simple_plot.Rproj deleted file mode 100644 index 8e3c2eb..0000000 --- a/r/simple_plot/simple_plot.Rproj +++ /dev/null @@ -1,13 +0,0 @@ -Version: 1.0 - -RestoreWorkspace: Default -SaveWorkspace: Default -AlwaysSaveHistory: Default - -EnableCodeIndexing: Yes -UseSpacesForTab: Yes -NumSpacesForTab: 2 -Encoding: UTF-8 - -RnwWeave: Sweave -LaTeX: pdfLaTeX diff --git a/run_quarto_publish.sh b/run_quarto_publish.sh new file mode 100644 index 0000000..aae22b3 --- /dev/null +++ b/run_quarto_publish.sh @@ -0,0 +1,110 @@ +#!/bin/bash + +# Activate the virtual environment +source /opt/venv/bin/activate +echo 'activated virtualenv.' + +# Run the Quarto extension installation +chmod +x /workspace/r/install_quarto_extensions.expect +/workspace/r/install_quarto_extensions.expect +quarto list extensions + +# Check Quarto and Rscript status +echo 'Check Quarto status:' +quarto check +echo 'Check R script path:' +which Rscript + +# Define folders to process +FOLDERS=(python r) +echo "Folders to process: ${FOLDERS[@]}" + +conda update conda +echo "Update conda" + +# Process .qmd and .ipynb files in the specified folders +for FOLDER in "${FOLDERS[@]}"; do + echo "Searching for .qmd and .ipynb files in /workspace/$FOLDER..." + find "/workspace/$FOLDER" \( -name '*.qmd' -o -name '*.ipynb' \) | while read -r file; do + + echo "Processing file: $file" + # Remove the /workspace prefix from the file path + relative_dir=$(dirname "${file#'/workspace/'}") + + # Create a virtual environment inside each folder under .venv + if [[ "$FOLDER" == "python" ]]; then + venv_path="/workspace/$relative_dir/.venv" + echo "Creating virtual environment at: $venv_path" + python3 -m venv "$venv_path" + source "$venv_path/bin/activate" + echo "Activated virtual environment in $venv_path" + + # Install requirements if there is a requirements.txt + if [[ -f "/workspace/$relative_dir/requirements.txt" ]]; then + pip install -r "/workspace/$relative_dir/requirements.txt" + fi + fi + + # Create a Conda environment for R folders + if [[ "$FOLDER" == "r" ]]; then + conda_env_name=$(echo "$relative_dir" | sed 's/\//_/g')_conda_env + echo "Creating Conda environment: $conda_env_name" + + if [[ -f "/workspace/$relative_dir/environment.yml" ]]; then + echo "Found environment.yml. Creating environment from file..." + conda env create -n "$conda_env_name" -f "/workspace/$relative_dir/environment.yml" + else + echo "environment.yml not found. Creating a minimal Conda environment with R..." + conda create -y -n "$conda_env_name" r-base=4.4.1 # Create a minimal Conda environment with R + fi + source activate "$conda_env_name" + echo "Activated Conda environment: $conda_env_name" + R -e '.libPaths(c("/usr/local/lib/R/site-library", .libPaths()))' + + # Run install_packages.R if it exists + if [[ -f "/workspace/$relative_dir/install_packages.R" ]]; then + Rscript "/workspace/$relative_dir/install_packages.R" + fi + fi + + # Install extensions in the folder + # TODO: investigate smarter way to install gobally + pushd $relative_dir + /workspace/r/install_quarto_extensions.expect + popd + + # Define the target directory for the output + target_dir="/workspace/gallery/$relative_dir" + echo "Creating target directory: $target_dir" + mkdir -p "$target_dir" && echo "Directory $target_dir created." + + # Attempt to render the file with execution + echo "Attempting to render $file with execution..." + if quarto render "$file" --to html --output-dir "$target_dir"; then + echo "Successfully rendered $file with execution." + else + echo "Failed to render $file with execution. Rendering without execution..." + if quarto render "$file" --to html --no-execute --output-dir "$target_dir"; then + echo "Successfully rendered $file without execution." + else + echo "Rendering failed for $file, even without execution." + fi + fi + + # Deactivate and delete virtual environment for Python folders + if [[ "$FOLDER" == "python" ]]; then + deactivate + echo "Deactivated virtual environment: $venv_path" + rm -rf "$venv_path" + echo "Deleted virtual environment: $venv_path" + fi + + # Deactivate and delete the Conda environment for R folders + if [[ "$FOLDER" == "r" ]]; then + conda deactivate + conda remove -y --name "$conda_env_name" --all + echo "Deleted Conda environment: $conda_env_name" + fi + + done +done