R conda env live task
Live task to run R snippets in conda a shell environment.
Conda-based R live tasks allow to execute R snippets on the fly in isolated conda environments.
Live tasks are fast and efficient tools to develop, test, use and share code snippets.
Warning: It is recommended to use code snippets comming from trusted sources.
Here is the general documentation for live task (including how to use the parameters): https://constellab.community/bricks/gws_core/latest/doc/developer-guide/live-task/getting-started
Here is the documentation of the live task: https://constellab.community/bricks/gws_core/latest/doc/developer-guide/live-task/env-live-task
Please give one parameter definition per line (https://constellab.community/bricks/gws_core/latest/doc/developer-guide/live-task/getting-started#parameters)
YAML configuration of the R conda environment
name: .venv channels: - conda-forge dependencies: - r-base
The R code snippet to execute using shell command
# This is a snippet template for a R live task. # Read the source csv file with header, row names and comma separator csv <- read.csv(source_paths, header = TRUE, sep = ",", row.names = 1) # Transpose the table, keep the header csv_result <- t(csv) # Write the csv file into the result folder result_path <- "result.csv" write.csv(csv_result, file = result_path, row.names = TRUE, col.names = TRUE) target_paths <- c(result_path)